Maximum request/response message size BizTalk WCF adapter can handle RRS feed

  • Question

  • My BizTalk application calls a WCF service using WCF-BasicHttp adapter and the passes very larges messages. It fails when I try to process request XML of 120 MB (the response will be around 60 MB) and fails with below error. I have set the maximum value for Maximum Received Message Size (2,147,483,647) on Send adapter. What is the maximum request/response message size WCF adapter can handle?? What other options we have to increase message size to process such large messages.

    System.ServiceModel.CommunicationException: An error occurred while receiving the HTTP response to "Service URI". 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. ---> System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a receive. ---> System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host

       at System.Net.Sockets.Socket.EndReceive(IAsyncResult asyncResult)

       at System.Net.Sockets.NetworkStream.EndRead(IAsyncResult asyncResult)

       --- End of inner exception stack trace ---

       at System.Net.Sockets.NetworkStream.EndRead(IAsyncResult asyncResult)

       at System.Net.PooledStream.EndRead(IAsyncResult asyncResult)

       at System.Net.Connection.ReadCallback(IAsyncResult asyncResult)

       --- End of inner exception stack trace ---

       at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)

       at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result)

       --- End of inner exception stack trace ---


    Regards, Ajeet Kumar MCTS Biztalk Server
    Wednesday, January 25, 2012 8:49 PM


  • Based on the stack trace, your error is not the typical overflow error. Yours looks like a network reset like a firewall event. This could possibly be due to the size of the message, time it takes to process, but WCF is not throwing an overflow error here.

    But since you asked about large messages, I would switch over to using the WCF-Custom adapter with BasicHttpBinding or WSHttpBinding because this exposes the ReaderQuota settings that you can also increase in value to avoid overflow events.



    If this answers your question, please use the "Answer" button to say so | Ben Cline
    Thursday, January 26, 2012 5:50 AM