John.O'[email protected] wrote:
Hi,

I'm using commons-httpclient-3.0.1, jre 1.6.0_16. I have a situation where I'm using the HttpClient to do a get, and the call hangs. The thread has hung at java.net.SocketInputStream.socketRead0. I've set the socket timeout at two points:
default timeout:
MultiThreadedHttpConnectionManager.getParams().setSoTimeout(60 * 1000);
method timeout:
GetMethod.getParams().setSoTimeout(30 * 1000);

This bug is tough to reproduce, but I have a system in this state. Getting the heap dump, I double checked the value of the socket timeout, and it is still set to 30 seconds, as expected.

I'm sorry if this is the wrong place to post (considering the issue seems to be in java.net.SocketInputStream), but I wanted to see if anyone had come across this situation.


John,

Please note the socket timeout is the maximum period of inactivity between two consecutive data packets. If the server sends a packet every 30 seconds the connection will never time out.

Oleg

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to