Roland, yes, thanks for the info.

Thanks,
Nate Gardner




Roland Weber <[EMAIL PROTECTED]> 
06/16/2007 05:50 AM
Please respond to
"HttpClient User Discussion" <[email protected]>



To
HttpClient User Discussion <[email protected]>
cc



Subject
Re: When exactly does a socket timeout get triggered?




Caterpillar: Confidential Green Retain Until: 07/16/2007        Retention 
Category:  G90 - General Matters/Administration


Hello Nathan,

> When exactly does a socket timeout get triggered?
> 
> Is it when the SO_TIMEOUT time has been reached and the first byte of 
data 
> has not been received?

Yes. Socket timeouts are per read operation. If you receive a
response, even with only a single byte of data, before the
timeout hits, then the read operation succeeds. If you want
to read more data, you have to call another read operation,
which will start a new timeout interval. This is not specific
to HTTP, it's general socket behavior:
http://java.sun.com/j2se/1.4.2/docs/api/java/net/Socket.html#setSoTimeout(int)


hope that helps,
  Roland


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Reply via email to