Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to configure maximum number of simultaneous connections in grpc

I am relatively new to grpc. I have followed the grpc java tutorial and have been able to generate the required classes using protocol buffer and got the client and server running, which is all good. Now I was wondering how many simultaneous client connections the server can take? Is there any way to configure it?

The reason I need to know it is that I will be deploying the server on a 32-thread machine, and each client request will be handled by a bunch of parallel worker threads. So I need some metrics as to (up to) how many threads I should spawn per request, since that should be limited by the number of simultaneous connections the server can accept.

like image 767
Asif Iqbal Avatar asked May 20 '16 04:05

Asif Iqbal


1 Answers

There currently is no limit. There is NettyServerBuilder.maxConcurrentCallsPerConnection(), which is related but insufficient by itself. I created a issue for tracking.

This sort of thing is definitely coming, although the exact form of it is still being designed.

like image 74
Eric Anderson Avatar answered Sep 28 '22 10:09

Eric Anderson