I use nginx in this mode for BOSH and chat clients along with gzip.
location ~* /http-bind/ {
proxy_buffering off;
keepalive_timeout 55;
access_log off;
tcp_nodelay on;
proxy_pass http://x.x.x.x:1111;
}
Is this the best approach to managing long polling in nginx.
I also use just one worker process for altogether for web & chat (single CPU). Is that fine?
From nginx.org, "For Comet applications based on long-polling it is important to set proxy_buffering to off, otherwise the asynchronous response is buffered and the Comet does not work.".
You might want to see this thread too.