Browse Source

js-executor log cleanup

pull/6888/head
Sergey Matvienko 4 years ago
parent
commit
b9a7d4a6d9
  1. 6
      msa/js-executor/queue/kafkaTemplate.js

6
msa/js-executor/queue/kafkaTemplate.js

@ -65,15 +65,15 @@ async function pushMessageToSendLater(message) {
function sendLoopWithLinger() { function sendLoopWithLinger() {
if (sendLoopInstance) { if (sendLoopInstance) {
clearTimeout(sendLoopInstance); clearTimeout(sendLoopInstance);
} else { // } else {
logger.debug("Starting new send loop with linger [%s]", linger) // logger.debug("Starting new send loop with linger [%s]", linger)
} }
sendLoopInstance = setTimeout(sendMessagesAsBatch, linger); sendLoopInstance = setTimeout(sendMessagesAsBatch, linger);
} }
async function sendMessagesAsBatch(isImmediately) { async function sendMessagesAsBatch(isImmediately) {
if (sendLoopInstance) { if (sendLoopInstance) {
logger.debug("sendMessagesAsBatch: Clear sendLoop scheduler. Starting new send loop with linger [%s]", linger); // logger.debug("sendMessagesAsBatch: Clear sendLoop scheduler. Starting new send loop with linger [%s]", linger);
clearTimeout(sendLoopInstance); clearTimeout(sendLoopInstance);
} }
sendLoopInstance = null; sendLoopInstance = null;

Loading…
Cancel
Save