jim0987795064 commented on code in PR #19776: URL: https://github.com/apache/kafka/pull/19776#discussion_r2105787616
########## clients/src/main/java/org/apache/kafka/clients/admin/KafkaAdminClient.java: ########## @@ -2494,8 +2494,7 @@ void handleResponse(AbstractResponse abstractResponse) { DescribeClusterResponse response = (DescribeClusterResponse) abstractResponse; Errors error = Errors.forCode(response.data().errorCode()); if (error != Errors.NONE) { - ApiError apiError = new ApiError(error, response.data().errorMessage()); - handleFailure(apiError.exception()); + handleFailure(error.exception(response.data().errorMessage())); Review Comment: Hi @m1a2st, Thanks for pointing this out! You're absolutely right — this change is unrelated to the main scope of this PR. I'll move it to a separate pull request to keep things clean and focused. Thanks for your feedback! -- 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