Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Idle TCP connection timeout

30 views
Skip to first unread message

mdwi...@yahoo.com

unread,
Apr 14, 2006, 2:47:59 PM4/14/06
to
Based on the comment below from this newsgroup I am surprised to see an
"expiration" time of 60 seconds on my system. This is consistant. I
can do requests 59 seconds apart and never see a socket expire. I've
checked the WinHttp trace and verified that the server is not closing
the connection. So my questions are:

For version 5.1.2600.2180 of WinHTTP does 60 seconds seem reasonable
for the expiration of an idle TCP connection?

Is there a way to change this timeout? I've tried
WINHTTP_OPTION_CONNECT_TIMEOUT
not really expecting it to work and it didn't. Is there any option
that applies to expired sockets?

And finally, why such a short timeout?

Thanks,
Mike


<<As for the "timeout value of an established TCP connection," do you
mean the
<<timeout of an idle TCP connection--that is, a socket sitting in the
pool and
<<not being used--when will WinHTTP close it? That is quite tricky to
<<explain--it depends on what version of WinHTTP you are using and what
your
<<application is doing. Roughly, WinHTTP will consider an idle socket
in the
<<pool to be "expired" if the socket has not been used for about two
minutes.
<<WinHTTP will not use an expired socket in subsequent HTTP requests;
it will
<<be discarded. (Also, even if a socket has not "expired", the server
may have
<<closed its side of the connection, forcing WinHTTP to discard the
socket.)

0 new messages