conf is configured as follows
security_ui is a static page, access is OK
http://safeguard corresponds to daemon
for example, when visiting http://localhost:8090/api/index?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null
, sometimes pending, is very fast, sometimes it takes a long time to get a response
what"s going on?
ps: does not need port 8090 for nginx routing, it is no problem to use 8080 directly
upstream safeguard{
server localhost:8080;
-sharpserver 192.168.194.72:8013;
-sharpip_hash;
}
server {
listen 8090;
server_name localhost;
-sharpcharset koi8-r;
-sharpaccess_log logs/host.access.log main;
location / {
root html;
proxy_pass http://safeguard;
index index.html index.htm;
}
location /security_ui {
root D:\svn\safeGuard;
index index.html index.htm;
}
nginx log log:
2018/03/27 19:25:04 [error] 11868-sharp9296: *192 upstream timed out (10060: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond) while connecting to upstream, client: 127.0.0.1, server: localhost, request: "GET /api/index/pIndex?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null HTTP/1.1", upstream: "http://[::1]:8080/api/index/pIndex?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null", host: "localhost:8090", referrer: "http://localhost:8090/security_ui/html/index.html?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null"
2018/03/28 10:48:02 [error] 4092-sharp212: *7 upstream timed out (10060: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond) while connecting to upstream, client: 127.0.0.1, server: localhost, request: "GET /api/index/pIndex?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null HTTP/1.1", upstream: "http://[::1]:8080/api/index/pIndex?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null", host: "localhost:8090", referrer: "http://localhost:8090/security_ui/html/index.html?msisdn=bc65670205bff064f878d61afa2e98b5&channel=null"