Hi,
In my module, I am capturing the request body to check if the body contains
some specific content. If the body does not contain the specific content
then I pass on the request without modification. Otherwise, I send a
HTTP_FORBIDDEN. I am using 'ngx_http_read_client_request_body' call to
capture the body.  Everything seems to be working fine. My requests are
forwarded to the orgin server and my client is receiving the response from
the origin server correctly.

However, what I notice is that the nginx is not releasing the client side
(see below). Nginx status module reports same number of active connections
in 'writing' state. Is there something special I need to do in my module to
ensure the connections are closed properly when I am capturing body? Any
help is greatly appreciated. Thanks.

Regards,
Dk.

[centos@ip-10-50-18-73 nginx]$ netstat -n | grep CLOSE_WAIT | head -4
tcp        1      0 10.50.18.73:443         10.50.30.239:60116
 CLOSE_WAIT
tcp        1      0 10.50.18.73:443         10.50.30.239:60092
 CLOSE_WAIT
tcp        1      0 10.50.18.73:443         10.50.30.239:60112
 CLOSE_WAIT
tcp        1      0 10.50.18.73:443         10.50.30.239:60054
 CLOSE_WAIT
[centos@ip-10-50-18-73 nginx]$ netstat -n | grep CLOSE_WAIT | wc -l
35
[centos@ip-10-50-18-73 nginx]$ [centos@ip-10-50-18-73 nginx]$ curl -k
https://localhost/nginx_status
Active connections: 37
server accepts handled requests
 41 41 472
Reading: 0 Writing: 36 Waiting: 1
[centos@ip-10-50-18-73 nginx]$
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel

Reply via email to