4. prosince 2006 22:36I've been getting the following System.ServiceModel.CommunicationException in a service client:An error occurred while receiving the HTTP response to http://myService.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.
The client code is as follows:
MyServiceClient service = new MyServiceClient();
List<myReturnType> myReturnCollection = service.ReturnList(someInt, someEnum.Item1);
This code works fine in our development and testing environment. But it returns the communication exception in the staging environment. After tracing the client messages, I found the exception occurs immediately after the third iteration of this method call. The connection is forcibly closed.
Obviously I'm facing a configuration issue. Before I start turning knobs, I'm hoping someone might be able to point me in the right direction. TIA
5. prosince 2006 18:33As follow up, here is the binding configuration I am using.
<binding name="soap11" bypassProxyOnLocal="true" maxBufferSize="6553600" maxReceivedMessageSize="6553600">
<readerQuotas maxStringContentLength="128000" />
5. prosince 2006 20:47I found the problem was in the maxItemsInObjectGraph value in both the service behavior configuration and in the client endpiont configuration was too small. I increased this value and this solved the problem.
I should have reviewed the error trace from the service log more carefully. It told me exactly what the problem was.