diff src/http/modules/ngx_http_proxy_module.c @ 6467:91c8d990fb45

Upstream: proxy_next_upstream non_idempotent. By default, requests with non-idempotent methods (POST, LOCK, PATCH) are no longer retried in case of errors if a request was already sent to a backend. Previous behaviour can be restored by using "proxy_next_upstream ... non_idempotent".
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 28 Mar 2016 19:50:19 +0300
parents 44122bddd9a1
children f01ab2dbcfdc
line wrap: on
line diff
--- a/src/http/modules/ngx_http_proxy_module.c
+++ b/src/http/modules/ngx_http_proxy_module.c
@@ -213,6 +213,7 @@ static ngx_conf_bitmask_t  ngx_http_prox
     { ngx_string("error"), NGX_HTTP_UPSTREAM_FT_ERROR },
     { ngx_string("timeout"), NGX_HTTP_UPSTREAM_FT_TIMEOUT },
     { ngx_string("invalid_header"), NGX_HTTP_UPSTREAM_FT_INVALID_HEADER },
+    { ngx_string("non_idempotent"), NGX_HTTP_UPSTREAM_FT_NON_IDEMPOTENT },
     { ngx_string("http_500"), NGX_HTTP_UPSTREAM_FT_HTTP_500 },
     { ngx_string("http_502"), NGX_HTTP_UPSTREAM_FT_HTTP_502 },
     { ngx_string("http_503"), NGX_HTTP_UPSTREAM_FT_HTTP_503 },