Thanks for your reply, we'll give a try to your suggestions.

2015-04-29 23:15 GMT+02:00 Christopher Schultz <ch...@christopherschultz.net
>:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
>
> Thomas,
>
> On 4/25/15 4:25 AM, Thomas Boniface wrote:
> > When talking about the strategy for our next test on the release we
> > checked at the tomcat connector configuration but we are unsure how
> > to applies your advices:
> >
> > 1. Check the nginx configuration. Specifically, the keep-alive and
> > timeout associated with the proxy configuration.
> >
> > 2. Make sure that Tomcat's timeouts are appropriate for those
> > matching settings in nginx.
> >
> > It seems were have 100 connections max keept alive at nginx level
> > ( keepalive), a timeout to connect to tomcat of 2s
> > (proxy_connect_timeout) and a timeout to read from tomcat of 10s
> > (proxy_read_timeout).
> >
> > On tomcat side we have a connector like follows:
> >
> > <Connector port="8080"
> > protocol="org.apache.coyote.http11.Http11NioProtocol"
> > selectorTimeout="1000" maxThreads="200" maxHttpHeaderSize="16384"
> > address="127.0.0.1" redirectPort="8443"/>
>
> It sounds like you need to add this to your <Connector> configuration:
>
>    connectionTimeout="10000"
>
> This matches your value for proxy_read_timeout. You should probably
> also set keepAliveTimeout if you think it needs to be different from
> connectionTimeout (keepAliveTimeout defaults to connectionTimeout).
>
> I'm not sure if Nginx's proxy_read_timeout is the same timeout used to
> terminate a connection to Tomcat if Nginx hasn't tried to send a
> request over that connection for a while, but if so, the
> connectionTimeout/keepAliveTimeout is what you want to set.
>
> I'm not sure that setting selectorTimeout to something other than the
> default helps you at all (1000ms is the default).
>
> The goal is to get both Nginx and Tomcat to close their connections at
> the same time when they decide that the connection is no loner
> necessary. If Nginx times-out more quickly than Tomcat, then re-opens
> a new connection to Tomcat, it will make Tomcat artificially run out
> of connections (and file descriptors) even though Tomcat is largely idle
> .
>
> - -chris
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2
> Comment: GPGTools - http://gpgtools.org
>
> iQIcBAEBCAAGBQJVQUnhAAoJEBzwKT+lPKRYzZwQAIgYxw6OuCgPeks/1S8x7bVP
> MdBdLddY9ruDNCRq9kLzKxEouo/WD5zuQW3kMRyTlX9I36HVRRcE6boaIwFBjiws
> LhoEMy6f5cZQj0FzRfstmyiyOFmZKtvAxwMVa8p1ykqkAhysDTU4fDKxmsKDk1fM
> fakJkqj4nRYP86ekFq/kIb/TNdMbzq+qx32QlevB/z+p0t7frR1DXadRK5KGXGVu
> dOHclY3Z29nzIGe+hdZULkZgpmAUDtk+Y7/bePeWv7ln6IBBoka7hYZGLj1+shdy
> PHrWs0ikTKTB9+kgS7OaipZD8r8x0yvtYYTEjZt3Jcsno0W2kKW600oTFI9YFJ2M
> XDu87+TUvb+E/NYLjJIPQICtDK71b0JpPt8ijQCx+91RFiFRYS8tuWNABcWbtRBb
> C2WlHmNilI/i+kAc7Syvao9gKO594jpao4nlPWhOXJK75QDw5K1szgo/ONgwujtU
> YRtpyZCVVB8UCUk8QIESL8WQT7zlP4MDlEpmeyRzhEGRcelCMoXEq22rZ4HVygAP
> iZg8KbkwUN/Ul7FMcwBbxoWOVE9iTBEj2nHuriAH5oKPnSJbuI2lfxOpxKSVMQaI
> NKV8Zb+yNby11UWWQxxI0QaStZB9IMVnCTLEMXT/M/okwd12xZKuChhh6RFaXKxL
> WIZLFHnxc4C5yWay7OPx
> =tLMj
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

Reply via email to