philipnee commented on code in PR #14406: URL: https://github.com/apache/kafka/pull/14406#discussion_r1338972414
########## clients/src/main/java/org/apache/kafka/clients/consumer/internals/AbstractFetch.java: ########## @@ -92,6 +88,23 @@ public AbstractFetch(final LogContext logContext, this.time = time; } + /** + * Check if the node is disconnected and unavailable for immediate reconnection (i.e. if it is in + * reconnect backoff window following the disconnect). + * + * @param node {@link Node} to check for availability + * @see NetworkClientUtils#isUnavailable(KafkaClient, Node, Time) + */ + protected abstract boolean isUnavailable(Node node); Review Comment: I am actually not sure if we need this as NetworkClientDelegate is already doing the connection checking. If the node is unavailable for reconnection, then it would fail the unsentRequest and presumably trigger a retry. The original code does the connection checking because the request is sent right after its creation; however, there's a time gap between the creation and the actual network IO. I think it is harmless to leave it here but it would be great if we could clean them up later. -- 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