From: bernd dot ott at k-m dot info Operating system: Windows PHP version: 5.2CVS-2009-02-05 (snap) PHP Bug Type: SOAP related Bug description: SoapClient leave tcp connections in "time_wait"
Description: ------------ Call to a Soapserver with the SoapClient leaves after a function call tcp-connection in state "time_wait". depending on your server your server get unreachable, because all workers are allocated by the waiting connections. the sample code leaves 100 open connections. if you call more than on function you get more open connections. the soapclient doesnt reuse the open connection. (this is not shown in the sample) the connections you can see in netstat or tcpview (sysinternals) Reproduce code: --------------- Client: <?php $i=100; while ($i>0) { $sc = new SoapClient(null, array('location' => "http://localhost/server.php", 'uri' => "http://test-uri/")); echo $sc->__soapcall("test", array('test'))."\r\n"; flush(); $i -= 1; } Server: <?php function test($x) { return $x."hallo"; } $server = new SoapServer(null, array('uri' => "http://test-uri/")); $server->addFunction("test"); $server->handle(); Expected result: ---------------- Client opens connection, does the function call and terminates connection. after correct close the should no connections in state "time_wait". Actual result: -------------- 100 connections are in time_wait status. -- Edit bug report at http://bugs.php.net/?id=47314&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=47314&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=47314&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=47314&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=47314&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=47314&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=47314&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=47314&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=47314&r=needscript Try newer version: http://bugs.php.net/fix.php?id=47314&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=47314&r=support Expected behavior: http://bugs.php.net/fix.php?id=47314&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=47314&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=47314&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=47314&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47314&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=47314&r=dst IIS Stability: http://bugs.php.net/fix.php?id=47314&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=47314&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=47314&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=47314&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=47314&r=mysqlcfg