-
Notifications
You must be signed in to change notification settings - Fork 15.4k
KAFKA-9232: Coordinator new member heartbeat completion does not work for JoinGroup v3 #7753
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
Changes from 1 commit
61a2acf
74a9fe9
8392273
151477f
321fb1c
18d441d
d4d9209
69477f8
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -88,7 +88,9 @@ private[group] class MemberMetadata(var memberId: String, | |
| def shouldKeepAlive(deadlineMs: Long): Boolean = { | ||
| if (isAwaitingJoin) | ||
| !isNew || latestHeartbeat + GroupCoordinator.NewMemberJoinTimeoutMs > deadlineMs | ||
| else awaitingSyncCallback != null || | ||
| else if (isNew || isAwaitingSync) | ||
|
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In
In 1. we ultimately set I refactored this a bit to reflect what (I think) makes sense: we want to always return true in the special cases of a) awaiting Sync, and b) between awaiting the Join and awaiting the Sync, ie, when
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Alternatively we could leave this method alone and change the ordering in member.isNew = false I think this also makes sense, and might be a bit more clear, but I'd want to verify that it's ok to move the heartbeat completion to before the
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm for simplifying if possible. What I am thinking is the following: Then I think this works with the reordering you suggested above: Upon rebalance completion, the first check will fail since we set
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok yeah I like that, the |
||
| true | ||
| else | ||
| latestHeartbeat + sessionTimeoutMs > deadlineMs | ||
| } | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
replaced
awaitingSyncCallback != nullwithisAwaitingSync