You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by ra...@apache.org on 2017/09/12 14:41:45 UTC
[incubator-openwhisk] branch master updated: Make nginx more
performant acting as a proxy. (#2727)
This is an automated email from the ASF dual-hosted git repository.
rabbah pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk.git
The following commit(s) were added to refs/heads/master by this push:
new 39669e6 Make nginx more performant acting as a proxy. (#2727)
39669e6 is described below
commit 39669e607298850ac73038f6c444ff02d720d7fc
Author: Markus Thömmes <ma...@me.com>
AuthorDate: Tue Sep 12 16:41:40 2017 +0200
Make nginx more performant acting as a proxy. (#2727)
This enables using HTTP keepalive towards the backend so the connections are reused more efficiently.
---
ansible/roles/nginx/templates/nginx.conf.j2 | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/ansible/roles/nginx/templates/nginx.conf.j2 b/ansible/roles/nginx/templates/nginx.conf.j2
index 53205b7..31c1ccf 100644
--- a/ansible/roles/nginx/templates/nginx.conf.j2
+++ b/ansible/roles/nginx/templates/nginx.conf.j2
@@ -4,7 +4,7 @@ worker_processes {{ nginx.wpn.router }};
events {
{# default: 1024 #}
- worker_connections 4096;
+ worker_connections 4096;
}
http {
@@ -18,6 +18,9 @@ http {
'$http_referer $http_user_agent $upstream_addr';
access_log /logs/nginx_access.log combined-upstream;
+ proxy_http_version 1.1;
+ proxy_set_header Connection "";
+
upstream controllers {
# fail_timeout: period of time the server will be considered unavailable
# Mark the controller as unavailable for at least 60 seconds, to not get any requests during restart.
@@ -30,6 +33,7 @@ http {
server {{ hostvars[ip].ansible_host }}:{{ controller.basePort + groups['controllers'].index(ip) }} backup;
{% endif %}
{% endfor %}
+ keepalive 512;
}
server {
--
To stop receiving notification emails like this one, please contact
['"commits@openwhisk.apache.org" <co...@openwhisk.apache.org>'].