Reputation: 75
When I look at the grpc-java auto-generated classes for the server calls and the sample examples given in the grpc-java git repo, I can see we extend the ImplBase class and override the service method. Like below:
static class communicationImpl extends communicationImplBase
In C++, to implement a Async Service we extend our implementation using AsyncService instead of Service class. But in java's generated Grpc class, i cannot see another class that is named/starting with Async. The only Server related class i see in there is the one ending with ImplBase. So how do i set up my server to process requests asynchronously in grpc-Java?
Upvotes: 3
Views: 6397
Reputation: 629
The ImplBase
class is the async interface, although for unary and server-streaming method it can be implemented in a blocking style.
Upvotes: 5