Re: [4.3.3] Newbie question about Stale Check
We upgraded to 4.5.2 and we are seeing only 200 SocketTimeoutExceptions now. Thanks Oleg -- View this message in context: http://httpcomponents.10934.n7.nabble.com/4-3-3-Newbie-question-about-Stale-Check-tp28119p28148.html Sent from the HttpClient-User mailing list archive at Nabble.com. - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org
Re: [4.3.3] Newbie question about Stale Check
On Fri, 2016-03-11 at 01:20 -0700, jappy wrote: > How does stale check actually work? By following the code it leads me to > SessionInputBufferImpl class > and there it is trying to read some data from the buffer. > What data is it trying to read? How do we actually say that this connection > is stale and close it? > Stale connection check is necessary to compensate for a limitation of the classic (blocking) i/o model of Java. Sockets in blocking i/o mode can only react to TCP packets when performing an i/o operation. When kept alive inside a connection pool connections are idle. They are not able to react to any action of the opposite endpoint. Stale check is effectively a very brief read operation with an extremely low timeout (1ms). If the operation times out the connection is fine. If it fails the connection is no longer valid. Please consider upgrading to 4.5.2 Oleg > The context behind this is we are seeing nearly 10K socket exceptions per > minute on our box. > and it all happens when it checks for stale connections and then trace ends > with a SocketTimeoutException > > Our setup is pretty simple. We have 10 different routes. With 5 max per > route. If I do a netstat on my box > I can see exactly 50 TCP connections on my box all in ESTABLISHED state. But > the above SocketTimeoutException doesn't make sense. As it all bubbles up in > checking for stale connections so wanted to know how it worked. > > Thanks in advance. > > > > -- > View this message in context: > http://httpcomponents.10934.n7.nabble.com/4-3-3-Newbie-question-about-Stale-Check-tp28119.html > Sent from the HttpClient-User mailing list archive at Nabble.com. > > - > To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org > For additional commands, e-mail: httpclient-users-h...@hc.apache.org > - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org
Re: [4.3.3] Newbie question about Stale Check
Can someone guide me in the correct direction. Any links or docs which I can follow -- View this message in context: http://httpcomponents.10934.n7.nabble.com/4-3-3-Newbie-question-about-Stale-Check-tp28119p28124.html Sent from the HttpClient-User mailing list archive at Nabble.com. - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org
[4.3.3] Newbie question about Stale Check
How does stale check actually work? By following the code it leads me to SessionInputBufferImpl class and there it is trying to read some data from the buffer. What data is it trying to read? How do we actually say that this connection is stale and close it? The context behind this is we are seeing nearly 10K socket exceptions per minute on our box. and it all happens when it checks for stale connections and then trace ends with a SocketTimeoutException Our setup is pretty simple. We have 10 different routes. With 5 max per route. If I do a netstat on my box I can see exactly 50 TCP connections on my box all in ESTABLISHED state. But the above SocketTimeoutException doesn't make sense. As it all bubbles up in checking for stale connections so wanted to know how it worked. Thanks in advance. -- View this message in context: http://httpcomponents.10934.n7.nabble.com/4-3-3-Newbie-question-about-Stale-Check-tp28119.html Sent from the HttpClient-User mailing list archive at Nabble.com. - To unsubscribe, e-mail: httpclient-users-unsubscr...@hc.apache.org For additional commands, e-mail: httpclient-users-h...@hc.apache.org