RE: Failed connection causes cascading libxml-related warnings?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



As it turns out, allow_url_fopen is turned off for this setup.  But the connection was refused to the WSDL resource because the server is not running; not because I'm disallowed from opening a stream to that resource.  The error message would have been different in that case, something like:

Warning: SoapClient::__construct() [function.soap-soapclient-construct]: URL file-access is disabled in the server configuration in /home/foo/bar/blah on line XX

SoapClient must use some other wrapper to retrieve remote WSDLs - one that isn't constrained by allow_url_fopen?

So I'm skeptical that those "other errors" - the stream-context resource warnings - are caused by the allow_url_fopen setting.  Even more because the XML documents being opened by SimpleXML and DOM functions are not remote, they're all on the local filesystem.

If it really is because of allow_url_fopen, _why_ is it?

-----Original Message-----
From: Claus Jørgensen [mailto:thedeathart@gmail.com] 
Sent: Monday, November 27, 2006 12:18 PM
To: soap@lists.php.net
Subject: Re:  Failed connection causes cascading libxml-related warnings?

Hey

Warning: SoapClient::__construct(http://devblahblah/foo?wsdl)
> [function.--construct]: failed to open stream: Connection refused in 
> /home/foo/php5/engine/lib/default.php on line 66


Sounds like you have allow_url_fopen set to 'off' in your php.ini. The other errors are caused by this problem.

--
Sincerely
  Claus Jørgensen

2006/11/27, Eby, Nicholas <NEby@newedgenetworks.com>:
>
> Good morning!  I'll try to describe a problem I'm having and ask if 
> anybody reading this list is familiar with it or has had a similar 
> experience.
>
> I'm working in a dev environment on my PHP5 framework that 
> incorporates the standard soap, DOM, and simplexml extensions.  There 
> are some data updates done thru our J2EE app using web services - and 
> in my dev environment, this morning the dev J2EE app was not running, 
> and one of my soap connections to retrieve a WSDL got refused.  This 
> caused errors something like:
>
> Warning: SoapClient::__construct(http://devblahblah/foo?wsdl)
> [function.--construct]: failed to open stream: Connection refused in 
> /home/foo/php5/engine/lib/default.php on line 66
>
> Warning: SoapClient::__construct() [function.--construct]: I/O warning :
> failed to load external entity "http://devblahblah/foo?wsdl"; in 
> /home/foo/php5/engine/lib/default.php on line 66
>
> Fatal error: Call to a member function __getLastResponse() on a 
> non-object in /home/foo/php5/engine/edgelink/mns.php on line 245
>
>
> Whatever, this is normal.  What is not normal, though, is what 
> happened next.  I now get intermittent warnings from anything 
> libxml-related, all with the same basic message:
>
> Warning: simplexml_load_file(): supplied argument is not a valid 
> Stream-Context resource in /home/foo/php5/engine/bin/foo.php on line 
> XX
>
> Warning: DOMDocument::load(): supplied argument is not a valid 
> Stream-Context resource in /home/foo/php5/engine/lib/xem.php on line 
> 87
>
> During any given request-response, if these warnings happen at all, 
> then they occur on every call to load a SimpleXML or DOM instance 
> (either from a file or from memory).  If the warnings do not happen, 
> then none of them happen.  Maybe 2 or 3 out of 10 executions produce 
> these warnings.
>
> (they're only warnings - that is, the relevant DOM or SimpleXML 
> instance is still instantiated successfully with the correct XML 
> content contained therein.)
>
> Uh... Wtf?
>
> Cheers,
> Nick Eby
> neby@newedgenetworks.com
>
> --
> PHP Soap Mailing List (http://www.php.net/) To unsubscribe, visit: 
> http://www.php.net/unsub.php
>
>

-- 
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux