Welcome! Log In Create A New Profile

Advanced

Re: Is grpc keepalive supported ?

Maxim Dounin
March 31, 2018 06:26PM
Hello!

On Sat, Mar 31, 2018 at 06:36:35AM -0400, bcoz123 wrote:

> Hello everyone,
> In the latest version(1.13.10)
> Does ‘grpc_pass’ support the ‘keepalive’ option ?
> My configuration is:
>
> ...
> http {
> ...
> upstream backend {
> server localhost:50051;
> keepalive 300;
> }
> server {
> listen 80 http2;
> location / {
> grpc_pass grpc://backend;
> }
> ...
> }
> ...
>
> It seems not work,
> Because I can still see for every request from the front,
> Nginx create a new tcp connection between nginx and backend every time.
> Is there something wrong in my configuration file?
> Or just it is not supported in this version ?

It is supported, though connections may still be closed in some
specific cases (unlikely to occur with valid gRPC requests
though). Note well that keepalive connection caches are
per-worker, so if you are using multiple worker processes you may
need to do multiple tests to see it working.

--
Maxim Dounin
http://mdounin.ru/
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Is grpc keepalive supported ?

bcoz123 March 31, 2018 06:36AM

Re: Is grpc keepalive supported ?

Maxim Dounin March 31, 2018 06:26PM

Re: Is grpc keepalive supported ?

bcoz123 April 02, 2018 03:47AM

Re: Is grpc keepalive supported ?

Maxim Dounin April 02, 2018 08:52AM

Re: Is grpc keepalive supported ?

bcoz123 April 03, 2018 06:51AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 306
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready