How to config Nginx for gRPC session sticky?

2019-05-29 Thread tjlp
I want to use nginx for gRPC loadbalance. And Nginx need to forward all the gRPC requests of a session to the same backend server. What is the recommended implementation? Thanks ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/l

回复:Nginx-lua Dynamic location to upstream

2017-03-23 Thread tjlp
You can refer to the open source Openresty. - 原始邮件 - 发件人:"nembo" 收件人:nginx@nginx.org 主题:Nginx-lua Dynamic location to upstream 日期:2017年03月23日 18点24分 Hi there, I've Just started to play with Lua (with nginx-plus) and this is what I'd like to achieve: I expose a location and a lua script W

回复:Re:_回复:Re:_回复:Re:_回复:Re:_回复:Re:_Issue_about_nginx_removing_the_header_"Connection"_in_HTTP_response?

2017-03-07 Thread tjlp
Hi, Aleks, This nginx conf is generated by Kubernetes nginx ingress controller. We use the Nginx in the kubernetes cluster. So many modules are there. The lua script is supported by the open sourced OpenResty. You can google it to find how and why use it. We use it for our special load balancin

回复:Re:_回复:Re:_回复:Re:_回复:Re:_Issue_about_nginx_removing_the_header_"Connection"_in_HTTP_response?

2017-03-07 Thread tjlp
Hi, Aleks, The result of nginx -V is as follow: nginx version: nginx/1.11.1 built by gcc 4.9.2 (Debian 4.9.2-10) built with OpenSSL 1.0.1t 3 May 2016 TLS SNI support enabled configure arguments: --prefix=/usr/share/nginx --conf-path=/etc/nginx/nginx.conf --http-log-path=/var/log/nginx/access.log

回复:Re:_回复:Re:_回复:Re:_Issue_about_nginx_removing_the_header_"Connection"_in_HTTP_response?

2017-03-06 Thread tjlp
Hi, Alexks, I try your proposal and it doesn't work. Actually my issue is the same as this one http://stackoverflow.com/questions/5100971/nginx-and-proxy-pass-send-connection-close-headers. 1. I add "keeplive_request 0". The result is that the "Connection: close" header is sent to client for e

回复:Re:_回复:Re:_回复:Re:_Issue_about_nginx_removing_the_header_"Connection"_in_HTTP_response?

2017-03-04 Thread tjlp
Hi, Aleks, Actually I read what you mention. The document about "proxy_pass_header" just pass the headers listed in "proxy_hide_header" which do not include "Connection", so I think it might doesn't work. I will try this. BTW, this module ngx_http_upstream_module should be built by default righ

回复:Re:_回复:Re:_Issue_about_nginx_removing_the_header_"Connection"_in_HTTP_response?

2017-03-04 Thread tjlp
Hi, Alexks, I don't want to hide the header. My problem is that Nginx change the "Connection: close" header in the reponse from upstream server to "Connction: keep-alive" and send to client. I want to keep the original "Connection: close" header. Thanks Liu Peng - 原始邮件 - 发件人:Aleksandar

回复:Re: Issue about nginx removing the header "Connection" in HTTP response?

2017-03-02 Thread tjlp
Hi, What I mention is the header in response from backend server. Your answer about proxy_set_header is the "Connection" header in request. Thanks Liu Peng - 原始邮件 - 发件人:Aleksandar Lazic 收件人:nginx@nginx.org 抄送人:t...@sina.com 主题:Re: Issue about nginx removing the header "Connection" in HT

Issue about nginx removing the header "Connection" in HTTP response?

2017-02-28 Thread tjlp
Hi, nginx guy, In our system, for some special requests, the upstream server will return a response which the header includes "Connection: Close". According to HTTP protocol, "Connection" is one-hop header. So, nginx will remove this header and the client can't do the business logic correctly

回复:Re: why "connection: close" header is added when the request is passed to upstream server?

2017-01-19 Thread tjlp
Hi, Maxim, You are right. Connection is hop-by-hop header. At present I add the line below into nginx.conf: proxy-set-headers Connection $http_connection That solve my issue. Thanks Liu Peng - 原始邮件 - 发件人:Maxim Dounin 收件人:nginx@nginx.org 主题:Re: why "connection: close" header is added w

why "connection: close" header is added when the request is passed to upstream server?

2017-01-18 Thread tjlp
Hi, Nginx guy, I use Nginx in the Kubernetes. With the upstream server log, I find that the header "connection: close" is added when the request is passed to upstream server. Why? What I hope is the original header relating to connection status should be passed to upstream server without any

How to config nginx to write the log to log file and standard output?

2016-12-20 Thread tjlp
Hi, Usually nginx writes log to access.log and error.log. How can I config nginx to write the log to these 2 log files and standard output? Thanks Liu Peng ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx

How to configure the nginx log to file and stdout at the same time?

2016-11-21 Thread tjlp
Hi, Is it possible to configure the nginx log to standard output (stdout or stderr) and log files at the same time? Thanks Liu Peng ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx

回复:Re: Can nginx has the capability to dynamically limit the connections when the upstream server has full load

2016-08-20 Thread tjlp
Hi, Bartenev, Our backend server is an old product existing for more than 20 years. When a client login in to the backend server, a session is created. The session will be terminated when the client log out. To prevent the server from out of memory issue, we can configure the max allowed sessio

Can nginx has the capability to dynamically limit the connections when the upstream server has full load

2016-08-18 Thread tjlp
Hi, I have a scenario: my backend servers provide URL to query whether this sever can accept new connections (the http response body is "true" or "false"). This server also has configuration for the max allowed session. Now I want to use Nginx as load balancer. Does Nginx provide such kind of