#36083 [NEW]: SoapClient waits for responses on one-way operations
| From: | bugs dot php at inspirationlabs dot net | Date: | Thu, 19 Jan 2006 11:57:41 +0000 |
| Subject: | #36083 [NEW]: SoapClient waits for responses on one-way operations | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-92189@lists.php.net to get a copy of this message | ||
From: bugs dot php at inspirationlabs dot net
Operating system: WinXP SP2, Apache/2.0.54 (Win32)
PHP version: 5.1.2
PHP Bug Type: SOAP related
Bug description: SoapClient waits for responses on one-way operations
Description:
------------
Try to call SoapService in one-way operation.
Client waits until SoapServer answeres. I think the SoapServer has to
return HTTP "202 Accepted" response (see Bug #32776), that is right, but
the response must been send before the Server executed
SoapServer->handle().
Reproduce code:
---------------
SoapClient:
<?php
$starttime = microtime(true);
$client = new SoapClient("oneway.wsdl", array( 'trace' => 1));
$client->foo("fooInput");
echo "UsedTime: ".(microtime(true) - $starttime);
?>
SoapServer:
<?php
function foo($input) {
sleep(7);
}
$Server = new SoapServer("oneway.wsdl");
$Server->addFunction("foo");
$Server->handle();
?>
WSDL (part):
<portType name="serverPortType">
<operation name="foo">
<input message="typens:foo"/>
</operation>
</portType>
<binding name="serverBinding" type="typens:serverPortType">
<soap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="foo">
<soap:operation soapAction="urn:serverAction"/>
<input>
<soap:body namespace="urn:oneway.wsdl" use="literal"/>
</input>
</operation>
</binding>
Expected result:
----------------
Server must answer under 1 Second, so Client Output Result is like:
UsedTime: 0.0034999847412
Actual result:
--------------
Server answers after sleep(7), Client waits until Server sending all
Headers. So Client Output Result is like:
UsedTime: 7.0034999847412 !!!
--
Edit bug report at http://bugs.php.net/?id=36083&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=36083&r=trysnapshot44
Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=36083&r=trysnapshot51
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=36083&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=36083&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=36083&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=36083&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=36083&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=36083&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=36083&r=support
Expected behavior: http://bugs.php.net/fix.php?id=36083&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=36083&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=36083&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=36083&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=36083&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=36083&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=36083&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=36083&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=36083&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=36083&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=36083&r=mysqlcfg