Skip to content
New issue

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

#1147 Allow disconnect on rebalance, currently if trying to rebalance kafka… #1462

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

samueltuckey
Copy link

@samueltuckey samueltuckey commented Oct 14, 2022

Trying to fix the bug where if we call disconnect on kafka consumer and a rebalance is in process then the disconnect does not work.
#1147

… will not disconnect properly if disconnect is called.
@samueltuckey samueltuckey changed the title Allow disconnect on rebalance, currently if trying to rebalance kafka… #1147 Allow disconnect on rebalance, currently if trying to rebalance kafka… Oct 14, 2022
samueltuckey and others added 5 commits October 19, 2022 14:43
@samueltuckey
Copy link
Author

samueltuckey commented Oct 21, 2022

@tulios @Nevon
This pull request will allow the consumer to call disconnect with an optional parameter allowReconnectAfterRebalance.
if allowReconnectAfterRebalance is set to false, then if the consumer calls disconnect while a rebalance is occurring then the rebalance won't automatically reconnect the consumer.

It does not change the default or affect any of the default behaviour that kafkajs provides it should not cause any problems to existing code.

Given the way the unit tests are structured, I am unsure about the way to engineer a unit test. Any recommendations would be appreciated.

typescript definitions are updated.

Please give me advice on how to get this pull request accepted.

Thanks in advance for your time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants