Never set a max queue size on the executor. Instead, use the ClientCall.request() and ServerCarll.request() methods to avoid overloading the queue. If your server or client is overloaded, just accept the RPC and immediately close it.
On Monday, June 10, 2019 at 8:48:16 PM UTC-7, [email protected] wrote: > > hi all > when build a grpc server by ServerBuilder, I use the > ServerBuilder.executor(myExecutor) to bind my own executor. I set the max > thread count 、queue capacity and throw rejectExecutionException when the > executor is full in the myExecutor. > > my question is : when the executor is full, how to catch the > exception and converted to the grpc status. Also I want the grpc client > distinguish > the error is cause by the reject of executor. > > > thank you. > -- You received this message because you are subscribed to the Google Groups "grpc.io" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/grpc-io/46e5c1e2-be43-4cfb-bbb5-be4b9e45d36c%40googlegroups.com.
