Re: The underlying connection was closed: An unexpected error occurred on a receive
From: RK (r_adhakrishna_at_yahoo.com)
Date: 11/03/04
- Next message: Sebastien Tardif: "RE: WSE 2.0 SP1 unable to consume WSDL from DIME Specification"
- Previous message: Patrick: "Re: WS-Policy and WSE problems!"
- In reply to: Guest: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Next in thread: subha: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Reply: subha: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Messages sorted by: [ date ] [ thread ]
Date: 3 Nov 2004 06:14:48 -0800
We had this problem earlier, but the fix in microsoft kb819450 worked
for us.
In our case C# class library is making call to web service.. so we
created wrapper class and added the following code in it..
class classWebServiceWrapper:myWebService
{
protected override WebRequest GetWebRequest(Uri uri)
{
HttpWebRequest webRequest =
(HttpWebRequest)base.GetWebRequest(uri);
webRequest.KeepAlive = false;
return webRequest;
}
}
so inside the class library instead calling web service directly, call
wrapper class as follows
myWebService ws = new classWebServiceWrapper();
ps:
protected override WebRequest GetWebRequest(Uri uri)
{
HttpWebRequest webRequest =
(HttpWebRequest)base.GetWebRequest(uri);
webRequest.KeepAlive = false;
return webRequest;
}
Adding this code in reference.cs file is also worked for us. but
everytime adding this part of the code is little extra work, so we
were using wrapper class.
goodluck.
--RK
Guest <Guest@aew_nospam.com> wrote in message news:<OnKxYcXwEHA.1408@TK2MSFTNGP10.phx.gbl>...
> > We are running IIS 6 on Win2003, with .Net 1.1. I have a client that
> > talks to my Web Service. The Web Service call is pretty lengthy (can
> > take more than a few minutes to complete).
> >
> > I noticed when the web service call takes more than ~180 seconds to
> > complete, the client will get the above exception. I tried calling
> > both synchronously and asynchronously call and they both failed with
> > the same error.
> >
> > If I increase the "Connection timeout" in the IIS Manager for the web
> > site, I can increase the time before the client will get the
> > exception. However, I don't expect the IIS to timeout my client
> > connection since the client is waiting for the server to complete the
> > call. I set the client side timeout to a huge number (int.MaxValue). I
> > tried WinXP with .Net 1.1 and I didn't have this error.
> >
> > I tried Q819450 but it didn't help. I cannot turn off Keep-alives
> > because I use Integrated Windows Authentication.
> >
> > Anyone know what might be the problem here?
> >
> > Thanks,
> > Joel
>
> Hello,
>
> You are describing exactly the same problem we have.
> Our webservice takes also long time to finish. If we are running on WinXP with IIS 5.1, there is no problem, but on Windows2003 with IIS 6.0, the client gets an exception.
> I tested with the 'turn-off keep-alives', but the problem was not resolved.
>
> Did you find any solution?
> Regards,
> Eric
>
> User submitted from AEWNET (http://www.aewnet.com/)
- Next message: Sebastien Tardif: "RE: WSE 2.0 SP1 unable to consume WSDL from DIME Specification"
- Previous message: Patrick: "Re: WS-Policy and WSE problems!"
- In reply to: Guest: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Next in thread: subha: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Reply: subha: "Re: The underlying connection was closed: An unexpected error occurred on a receive"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|