omkreddy commented on code in PR #20598:
URL: https://github.com/apache/kafka/pull/20598#discussion_r3667202261
##########
clients/src/main/java/org/apache/kafka/clients/admin/KafkaAdminClient.java:
##########
@@ -4585,8 +4596,11 @@ void handleResponse(AbstractResponse response) {
final ApiVersionsResponse apiVersionsResponse =
(ApiVersionsResponse) response;
if (apiVersionsResponse.data().errorCode() ==
Errors.NONE.code()) {
future.complete(createFeatureMetadata(apiVersionsResponse));
+
nodeApiVersionsFuture.complete(createNodeApiVersion(apiVersionsResponse));
} else {
-
future.completeExceptionally(Errors.forCode(apiVersionsResponse.data().errorCode()).exception());
+ Exception exception =
Errors.forCode(apiVersionsResponse.data().errorCode()).exception();
+ future.completeExceptionally(exception);
+ nodeApiVersionsFuture.completeExceptionally(exception);
Review Comment:
@TaiJuWu looks like describeFeatures() now exposes nodeApiVersionsFuture via
InternalDescribeFeaturesResult, but the call's handleFailure only completes the
FeatureMetadata future (via
completeAllExceptionally(Collections.singletonList(future), ...)). If the
request fails, nodeApiVersionsFuture is never completed, which can cause
callers to hang indefinitely waiting on nodeApiVersions().
cc @chia7712
--
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]