Mercurial > hg > nginx-tests
comparison stream_proxy_next_upstream.t @ 572:ca54b445d982
Tests: masked nginx bug in proxy next upstream.
When iterating through several next upstreams per a worker cycle,
a previously reported event about upstream connection error may
be improperly applied to the next upstream, thus leading to the
invalid connection error. E.g., in kqueue, where the problem is
visible, this is caused by "ev->instance" that does not tolerate
more than one next upstream at once, and kevents placed on the
kqueue separately for read and write events.
The change is to limit test case to the only one next upstream.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Thu, 14 May 2015 11:54:24 +0300 |
parents | ff49e1c00b35 |
children | 77359b849cd5 |
comparison
equal
deleted
inserted
replaced
571:5c3946ebd867 | 572:ca54b445d982 |
---|---|
40 server 127.0.0.1:8087 max_fails=0; | 40 server 127.0.0.1:8087 max_fails=0; |
41 server 127.0.0.1:8088 max_fails=0; | 41 server 127.0.0.1:8088 max_fails=0; |
42 server 127.0.0.1:8089 backup; | 42 server 127.0.0.1:8089 backup; |
43 } | 43 } |
44 | 44 |
45 upstream u2 { | |
46 server 127.0.0.1:8087; | |
47 server 127.0.0.1:8089 backup; | |
48 } | |
49 | |
45 proxy_connect_timeout 1s; | 50 proxy_connect_timeout 1s; |
46 | 51 |
47 server { | 52 server { |
48 listen 127.0.0.1:8081; | 53 listen 127.0.0.1:8081; |
49 proxy_pass u; | 54 proxy_pass u; |
50 proxy_next_upstream off; | 55 proxy_next_upstream off; |
51 } | 56 } |
52 | 57 |
53 server { | 58 server { |
54 listen 127.0.0.1:8082; | 59 listen 127.0.0.1:8082; |
55 proxy_pass u; | 60 proxy_pass u2; |
56 proxy_next_upstream on; | 61 proxy_next_upstream on; |
57 } | 62 } |
58 | 63 |
59 server { | 64 server { |
60 listen 127.0.0.1:8083; | 65 listen 127.0.0.1:8083; |