You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2020/10/19 15:37:45 UTC

[GitHub] [kafka] chia7712 commented on a change in pull request #9449: MINOR: simplify implementation of ConsumerGroupOperationContext.hasCo…

chia7712 commented on a change in pull request #9449:
URL: https://github.com/apache/kafka/pull/9449#discussion_r507852448



##########
File path: clients/src/main/java/org/apache/kafka/clients/admin/KafkaAdminClient.java
##########
@@ -3938,25 +3938,15 @@ private Call getAlterConsumerGroupOffsetsCall(ConsumerGroupOperationContext<Map<
             void handleResponse(AbstractResponse abstractResponse) {
                 final OffsetCommitResponse response = (OffsetCommitResponse) abstractResponse;
 
-                // If coordinator changed since we fetched it, retry
-                if (ConsumerGroupOperationContext.hasCoordinatorMoved(response)) {
+                // 1) If coordinator changed since we fetched it, retry
+                // 2) If there is a coordinator error, retry
+                if (ConsumerGroupOperationContext.hasCoordinatorMoved(response) ||
+                    ConsumerGroupOperationContext.shouldRefreshCoordinator(response)) {

Review comment:
       You are right!




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org