smjn commented on code in PR #18824:
URL: https://github.com/apache/kafka/pull/18824#discussion_r1946270238
##########
server-common/src/main/java/org/apache/kafka/server/share/persister/PersisterStateManager.java:
##########
@@ -356,16 +367,48 @@ public void onComplete(ClientResponse response) {
if (onCompleteCallback != null) {
onCompleteCallback.accept(response);
}
- if (response != null && response.hasResponse()) {
- if (isFindCoordinatorResponse(response)) {
+
+ // We don't know if FIND_COORD or actual REQUEST. Let's err on
side of request.
Review Comment:
@AndrewJSchofield Thanks for the review!
No, the signature of `onComplete` cannot be changed as this method is
declared in the general `RequestCompletionHandler` interface implemented by RPC
handlers.
The `InterBrokerSendThread` periodically calls `SendThread.generateRequests`
which encapsulates the request as a `RequestAndCompletionHandler` whose
argument for the request handler is `RequestCompletionHandler`. Then in
`RequestCompletionHandler.onComplete` is called which only accepts the
clientResponse.
--
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]