Interface ClientHandlerCallback<RESP extends MessageBody>
Callback for
ClientHandler.-
Method Summary
Modifier and TypeMethodDescriptionvoidCalled on any failure, which is not related to a specific request.voidonRequestFailure(long requestId, Throwable cause) Called on a failed request.voidonRequestResult(long requestId, RESP response) Called on a successful request.
-
Method Details
-
onRequestResult
Called on a successful request.- Parameters:
requestId- ID of the requestresponse- The received response
-
onRequestFailure
Called on a failed request.- Parameters:
requestId- ID of the requestcause- Cause of the request failure
-
onFailure
Called on any failure, which is not related to a specific request.This can be for example a caught Exception in the channel pipeline or an unexpected channel close.
- Parameters:
cause- Cause of the failure
-