petrov-mg commented on code in PR #11176:
URL: https://github.com/apache/ignite/pull/11176#discussion_r1485637906
##########
modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/ClientRequest.java:
##########
@@ -58,4 +59,21 @@ public ClientRequest(long reqId) {
public ClientResponse process(ClientConnectionContext ctx) {
return new ClientResponse(reqId);
}
+
+ /**
+ * Processes the request asynchronously.
+ *
+ * @return Future for response.
+ */
+ public IgniteInternalFuture<ClientResponse>
processAsync(ClientConnectionContext ctx) {
Review Comment:
Have you considered just replacing the "process" method with "processAsync"?
For the first glance it might help avoid creating `isAsync` method and
`ClientListenerAsyncResponse`. It looks a bit confusing that it's up to a outer
code to decide whether to run `sync` or `async` method to process
`ClientRequest` while `ClientRequest` itself knows how it should be processed.
On the other hand it will lead to creating CompletedFuture wrappers and a
bit of refactoring.
--
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]