|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-07-07 17:58 UTC] akomasinski at gmail dot com
[2009-09-09 11:03 UTC] sjoerd@php.net
[2009-09-14 10:00 UTC] maximchick at gmail dot com
[2009-09-14 12:36 UTC] maximchick at gmail dot com
[2009-12-11 13:00 UTC] arekm at maven dot pl
[2010-01-18 17:25 UTC] johnm04 at gmail dot com
[2010-01-18 17:43 UTC] johnm04 at gmail dot com
[2014-02-06 09:52 UTC] bhimraogadge at gmail dot com
[2014-08-06 14:29 UTC] m dot staab at complex-it dot de
[2014-08-07 16:59 UTC] rdlowrey@php.net
-Status: Open
+Status: Closed
-Operating System: Linux
+Operating System: *
-PHP Version: 5.2.9
+PHP Version: 5.2 - 5.6
-Assigned To:
+Assigned To: rdlowrey
[2014-08-07 16:59 UTC] rdlowrey@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 19:00:02 2025 UTC |
Description: ------------ The default_socket_timeout option is not taken in consideration when making SOAP requests to a HTTPS URL. This causes big issues for us because, if the server hung for some reason, the client waits forever to get a reply back. The code works correctly when using HTTP URLs. But in our production environment we need to use HTTPS so this is not a workaround. Reproduce code: --------------- SOAP Server code: $Server = new SoapServer('ed.wsdl'); $Server->setClass('Ed'); $Server->handle(); class Ed{ public function hello($Input){ sleep(30); return array('goodbye' => "Goodbye " . $Input->firstname); } } SOAP client code: echo "Start time: " . date('c') . "\n"; ini_set('soap.wsdl_cache_enabled', 0); ini_set('default_socket_timeout', 5); $Binding = new SoapClient('ed.wsdl', array('trace' => 1)); try { $Return = $Binding->hello(array('firstname' => 'john')); echo "Response: "; print_r($Return); } catch( Exception $e ) { echo "Exception: "; print_r($e); } echo "End time: " . date('c') . "\n"; Let me know if you need the wsdl file as well. Expected result: ---------------- I expect a SOAP timeout exception to be thrown. Actual result: -------------- The client gets the server response after 30 seconds, as shown here: Start time: 2009-06-10T11:58:30-07:00 Response: stdClass Object ( [goodbye] => Goodbye john ) End time: 2009-06-10T11:59:00-07:00