hachikuji commented on code in PR #13138:
URL: https://github.com/apache/kafka/pull/13138#discussion_r1084522285


##########
clients/src/main/java/org/apache/kafka/clients/consumer/internals/CoordinatorRequestManager.java:
##########
@@ -149,11 +156,14 @@ private void onSuccessfulResponse(final 
FindCoordinatorResponseData.Coordinator
                 coordinator.host(),
                 coordinator.port());
         log.info("Discovered group coordinator {}", coordinator);
-        coordinatorRequestState.reset();
+        coordinatorRequestState.onSuccessfulAttempt(currentTimeMs);
     }
 
-    private void onFailedCoordinatorResponse(final Exception exception, final 
long currentTimeMs) {
-        coordinatorRequestState.updateLastFailedAttempt(currentTimeMs);
+    private void onFailedResponse(
+        final long currentTimeMs,
+        final Throwable exception
+    ) {
+        coordinatorRequestState.onFailedAttempt(currentTimeMs);

Review Comment:
   True, but note the record time is provided as a parameters, so it doesn't 
actually matter. I was going to move this to the end of the method as well, but 
it requires a little refactoring here due to the shortcut returns.



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

Reply via email to