title: SOAP response size
body: <p>I'm attempting to consume a web service that has been creating using Soap::Lite (Perl).  I'm consuming the service using C#.  For the most part it works fine. I can grab responses and parse them as I see fit.  However, I have certain calls that do not work.</p>
  
  <p>I get the following message:
  "An existing connection was forcibly closed by the remote host"</p>
  
  <p>It's my understanding that the server is probably cutting off the connection for
  whatever reason. I'm trying to find that reason. I think it's happening due to
  the size of the details of some responses. I've got one in particular that will
  always fail and when I view the XML from the SOAP response, it is always
  truncated at the exact same spot as if it gets to that spot and has hit a size
  limit.</p>
  
  <p>So, I've done everything I can think of on the client size such as changing the
  MaxReceivedMessageSize and timeout settings, etc. I've noticed that I can
  increase timeouts and the execution time subsequently increases, but the diagnostics logging I'm doing always stops at the same spot.</p>
  
  <p>I've also written a class that allows me to view the raw XML and again, it stops at the same spot.</p>
  
  <p>I'm thinking maybe something on the server needs to changed but everything I've tried doesn't work.  The service is hosted on a web server running IIS 6.</p>
  
  <p>Does anyone have any suggestions for what I can do on either the client and/or server side?</p>
  
  <p>Thanks</p>
  
  <p>EDIT</p>
  
  <hr>
  
  <p>I should note that there is no WSDL file for me to use.  The application I'm working with is the only time I've ever worked with SOAP::Lite and from what I can tell it doesn't generate a WSDL.</p>
  
  <p>@e36M3 - Thanks for the suggestion.  I had never heard of soapUI. I installed it and tried it out and I can see many uses for it so I will be keeping it in mind for the future.  Unfortunately it seems to be build around WSDL testing and I can't see how to test with it without providing a WSDL which is a problem given this particular situation.</p>
  
  <hr>
  
  <p>Here is some of the relevant data from my trace logging.  It starts with where the invalid xml ends and ends with the error information.</p>
  
  <p>System.Net Verbose: 0 : [5772] 000031E0 ;/map>.&lt;/data <br/>
  System.Net Verbose: 0 : [5772] 000031E0 >.
  System.Net Verbose: 0 : [5772] 000031E0 esp1:MRWebServic <br/>
  System.Net Verbose: 0 : [5772] 000031E0 es__getIssueDeta <br/>
  System.Net Verbose: 0 : [5772] 000031E0 ilsResponse>
  System.Net Verbose: 0 : [5772] 000031E0 AP-ENV:Body>
  System.Net Verbose: 0 : [5772] 000031E0 AP-ENV:Envelope> <br/>
  System.Net Verbose: 0 : [5772] Exiting ConnectStream#15566556::Read()   -> 12880#12880&lt; br/>
  System.Net Verbose: 0 : [5772] ConnectStream#15566556::Read() <br/>
  System.Net.Sockets Verbose: 0 : [5772] Socket#20784002::Receive() <br/>
  System.Net.Sockets Error: 0 : [5772] Exception in the Socket#20784002::Receive - A   connection attempt failed because the connected party did not properly respond after a 
  period of time, or established connection failed because connected host has failed to 
  respond <br/>
  System.Net.Sockets Verbose: 0 : [5772] Exiting Socket#20784002::Receive()   -> 0#0 <br/>
  System.Net.Sockets Verbose: 0 : [5772] Socket#20784002::Dispose() <br/>
  System.Net Error: 0 : [5772] Exception in the HttpWebRequest#63722612:: - The underlying connection was closed: An unexpected error occurred on a receive.
  System.Net Verbose: 0 : [5772] ConnectStream#15566556::Close() <br/>
  System.Net Verbose: 0 : [5772] Exiting ConnectStream#15566556::Close()  <br/></p>