chickenchickenlove commented on code in PR #22473:
URL: https://github.com/apache/kafka/pull/22473#discussion_r3750277113
##########
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/GroupMetadataManager.java:
##########
@@ -4259,11 +4259,27 @@ private
CoordinatorResult<ConsumerGroupHeartbeatResponseData, CoordinatorRecord>
ConsumerGroup group,
ConsumerGroupMember member
) {
+ ConsumerGroupMember reconciledMember = member;
+ if (member.state() == MemberState.UNREVOKED_PARTITIONS) {
+ reconciledMember = new CurrentAssignmentBuilder(member)
+ .withMetadataImage(metadataImage)
+ .withTargetAssignment(
+ group.assignmentEpoch(),
+ group.targetAssignment(member.memberId())
+ )
+
.withResolvedRegularExpressions(group.resolvedRegularExpressions())
+ .withCurrentPartitionEpoch(group::currentPartitionEpoch)
+ .withOwnedTopicPartitions(List.of())
+ .build();
+ }
+
Review Comment:
@squah-confluent
I’m very sorry for the delayed response. 🙇♂️
I haven’t had much bandwidth to work on this recently.
That’s a great point. Since reconciledMember is treated as having revoked
all of its partitions while in the `UNREVOKED_PARTITIONS` state, it will
transition to either `STABLE` or `UNRELEASED_PARTITIONS`. As you mentioned, I
agree that we should also call `cancelGroupRebalanceTimeout()` here.
I’ve updated the code accordingly. Thank you for pointing this out!
When you get a chance, please take another look! 🙇♂️
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]