We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In highLevelConsumer.js there is this code:
highLevelConsumer.js
this.on('done', function (topics) { self.updateOffsets(topics); if (!self.paused) { setImmediate(function () { self.fetch(); }); } else { setTimeout(function () { self.fetch(); }, 1000); } });
The .fetch() function is as follows:
.fetch()
HighLevelConsumer.prototype.fetch = function () { if (!this.ready || this.rebalancing || this.paused) { return; } this.client.sendFetchRequest(this, this.topicPayloads, this.options.fetchMaxWaitMs, this.options.fetchMinBytes, this.options.maxTickMessages); }
This means that even if the consumer is paused, it will try to fetch every 1 second:
setTimeout(function () { self.fetch(); }, 1000);
Why try if the code in .fetch() will just return?
return
if (!this.ready || this.rebalancing || this.paused) { return; }
The text was updated successfully, but these errors were encountered:
offsetOutOfRange
Fix SOHU-Co#169: When paused why try to fetch every 1000 ms?
0738f4f
@jezzalaycock seems to have written those lines.
Sorry, something went wrong.
I think those lines can be removed.
Merge pull request #171 from kadishmal/fix.169
78044da
Fix #169: When paused why try to fetch every 1000 ms?
Successfully merging a pull request may close this issue.
In
highLevelConsumer.js
there is this code:The
.fetch()
function is as follows:This means that even if the consumer is paused, it will try to fetch every 1 second:
Why try if the code in
.fetch()
will justreturn
?The text was updated successfully, but these errors were encountered: