471,350 Members | 1,951 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,350 software developers and data experts.

System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a send.

When I invoke two web service methods sequentially with no delay, the first
web method invocation goes smooth while the 2nd one generates the dredded:

System.Net.WebException: The underlying connection was closed: An unexpected
error occurred on a send.

The only way I have been able to make consecutive web method invocations
work is by overriding GetRequest and disabling Keep-Alive. The IIS
Keep-Alive setting is enabled for 120 seconds but yet it appears that value
is not being honored by IIS for some reason. I would rather not disable
keep alive to make things work as doing so has network performance
implications. Has anyone gotten Http Keep-Alives to work in .NET 2.0?

Server = Win 2003 SP2 / .NET 2.0

Client = Win XP SP2 / .NET 2.0

thanks

ScottM
Jun 8 '07 #1
2 5557
Ok, for anyone interested, I solved the issue. At the time of the
WebException, I happened to be running Fiddler 2.0.9.0. Fiddler
automatically reconfigures IE proxy settings to support HTTP tracing.
Apparently, this version of fiddler has issues with HTTP-Keep alive. I
turned off Fiddler, re-ran my code and all is well.
ScottM
"Scott McFadden" <no**************@criticaltech.comwrote in message
news:Oh*************@TK2MSFTNGP02.phx.gbl...
When I invoke two web service methods sequentially with no delay, the
first web method invocation goes smooth while the 2nd one generates the
dredded:

System.Net.WebException: The underlying connection was closed: An
unexpected error occurred on a send.

The only way I have been able to make consecutive web method invocations
work is by overriding GetRequest and disabling Keep-Alive. The IIS
Keep-Alive setting is enabled for 120 seconds but yet it appears that
value is not being honored by IIS for some reason. I would rather not
disable keep alive to make things work as doing so has network performance
implications. Has anyone gotten Http Keep-Alives to work in .NET 2.0?

Server = Win 2003 SP2 / .NET 2.0

Client = Win XP SP2 / .NET 2.0

thanks

ScottM


Jun 8 '07 #2
I had the same problem and it was resolved after closing Fiddler.
I was looking for someone to confirm that Fiddler really was the culprit.
Thanks !

"Scott McFadden" wrote:
Ok, for anyone interested, I solved the issue. At the time of the
WebException, I happened to be running Fiddler 2.0.9.0. Fiddler
automatically reconfigures IE proxy settings to support HTTP tracing.
Apparently, this version of fiddler has issues with HTTP-Keep alive. I
turned off Fiddler, re-ran my code and all is well.
ScottM
"Scott McFadden" <no**************@criticaltech.comwrote in message
news:Oh*************@TK2MSFTNGP02.phx.gbl...
When I invoke two web service methods sequentially with no delay, the
first web method invocation goes smooth while the 2nd one generates the
dredded:

System.Net.WebException: The underlying connection was closed: An
unexpected error occurred on a send.

The only way I have been able to make consecutive web method invocations
work is by overriding GetRequest and disabling Keep-Alive. The IIS
Keep-Alive setting is enabled for 120 seconds but yet it appears that
value is not being honored by IIS for some reason. I would rather not
disable keep alive to make things work as doing so has network performance
implications. Has anyone gotten Http Keep-Alives to work in .NET 2.0?

Server = Win 2003 SP2 / .NET 2.0

Client = Win XP SP2 / .NET 2.0

thanks

ScottM


Jun 18 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by Sachin Surana | last post: by
2 posts views Thread by zolof | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.