lianetm commented on code in PR #14945: URL: https://github.com/apache/kafka/pull/14945#discussion_r1417895767
########## clients/src/main/java/org/apache/kafka/clients/consumer/internals/CommitRequestManager.java: ########## @@ -224,6 +224,13 @@ boolean canAutoCommit() { return autoCommitState.isPresent() && !subscriptions.allConsumed().isEmpty(); } + /** + * Updates the member ID and epoch upon receiving ConsumerGroupHeartbeatResponse. + */ + void updateMemberInformation(String memberId, int memberEpoch) { + groupState.generation = new GroupState.Generation(memberEpoch, memberId, null); + } Review Comment: Just for the record, with the fix in the commit PR the approach is having this CommitManager as a StateListener, that gets notified when epoch changes, so it gets the last value from the MembershipManager. I did the listener approach to avoid a circular dep (the MembershipMgr uses the CommitMgr to commit), and truly, this Commit does not need the whole MembershipMgr, it just needs to have the latest ID/epoch, so the listener seemed enough. Anyways, let's have this conversation on the other PR when in review. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org