2

I've spent almost two full days trying to resolve this issue, but to no avail. Any help is greatly appreciated.

I am trying to make a Soap Request in PHP using php's build in SoapClient. I have verified that trying to send a request where the size of envelope is smaller than 4MB works great. The communication between the called server and my client has no issues in this circumstance. As soon as I tip the size of the envelope just over 4MB, my php instance takes somewhere between 1-2 minutes to throw a SoapFault where the error message is "Error fetching HTTP headers". I have my max_post_size and memory_limits set to 150M in my php.ini and my IIS request limit is set to 500MB.

I have verified that if I am not using php to make the SOAP request, I can complete my request and response chain with bodies upwards of 4MB in no time at all, so I feel that I've narrowed this down to a php/SoapClient issue.

If anybody has any ideas, I would greatly appreciate the help. I am not sure what else to try at this point.

PHP Warning:  SoapClient::__doRequest(): SSL: An existing connection was forcibly closed by the remote host.
 in C:\myvu\services\vendor\vu\file_storage_client\FileStorageClient\File\VuStore\VuStoreFileManager.php on line 54
[07-May-2015 08:31:48 America/Chicago] Error Fetching http headers

Thank you!

Phil

  • sounds like a timeout issue if that's the case. – Jonathan May 07 '15 at 01:02
  • http://stackoverflow.com/questions/9403486/error-fetching-http-headers-in-soapclient – FuzzyTree May 07 '15 at 01:03
  • @FuzzyTree, I've tried increasing the default socket timeout and i am seeing the same results. I already tried multiple suggestions from that link. provided above. No dice so far.The part I find confusing, is that my machine has no trouble making a request from a C# application to the same WCF service. In fact, it takes less than 5 seconds to complete the 4MB request. Increasing a timeout in the php application seems like it wouldn't actually fix anything, but rather help diagnose the issue. – Phillip Hotchkiss May 07 '15 at 02:24
  • A little more information. The server that I am calling to doesn't seem to have any record in its access logs when I upload a file 4MB or greater. I believe the order of operations is as follows, php successfully opens a connection, holds open the connection with no data transfer, the server closes the connection, and the error fetching http headers happens. – Phillip Hotchkiss May 07 '15 at 14:24
  • I was able to complete the request using a curl in php, but I don't get the added benefit of it converting to a standard object and being able to use that off of the result, so I would prefer to use SoapClient in php. I am just not sure why the connection for content length of 4MB or greater would be rejected when using SoapClient and accepted when making an HTTP request. Any additional help would be great. Thanks so much for the input so far. – Phillip Hotchkiss May 07 '15 at 20:25
  • @PhillipHotchkiss what happens if you make the request without ssl/tls? – Brian C May 15 '15 at 14:00
  • @BrianC when trying over http, the request fails altogether. I believe it is a requirement for us for the request to be made over SSL. We could potentially toggle that requirement to see if it affects anything. What is your line of thinking? – Phillip Hotchkiss May 26 '15 at 00:43

0 Answers0