You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@xml.apache.org by "Jay Freeman (saurik)" <sa...@saurik.com> on 2001/02/25 14:32:52 UTC

ServiceManagerClient: Unable to resolve namespace URI for 'ns2'.

In trying to use ServiceManagerClient, I’m running into an annoying error
message.  I’m working with the latest CVS of xml-soap (although I have
tested that this fails with 2.1 as well) and the latest CVS of xml-xerces
(although an older CVS build from a few weeks ago failed as well).  Anyone
have any idea what is going on?

The command line:

java org.apache.soap.server.ServiceManagerClient
http://www.datauniversal.com:81/soap/servlet/rpcrouter list

What gets sent:

POST /soap/servlet/rpcrouter HTTP/1.0
Host: www.datauniversal.com:81
Content-Type: text/xml; charset=utf-8
Content-Length: 414
SOAPAction: ""

<?xml version='1.0' encoding='UTF-8'?>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/1999/XMLSchema">
<SOAP-ENV:Body>
<ns1:list xmlns:ns1="urn:xml-soap-service-management-service"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
</ns1:list>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

What gets returned:

HTTP/1.1 200 OK
Date: Sun, 25 Feb 2001 13:23:46 GMT
Server: Apache/1.3.14 (Unix)  (Red-Hat/Linux) DAV/1.0.2 PHP/4.0.4pl1 mod_jk
mod_ssl/2.7.1 OpenSSL/0.9.5a
Content-Length: 619
Set-Cookie: JSESSIONID=ajhctzp9w1;Path=/soap
Connection: close
Content-Type: text/xml; charset=utf-8

<?xml version='1.0' encoding='UTF-8'?>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/1999/XMLSchema">
<SOAP-ENV:Body>
<ns1:listResponse xmlns:ns1="urn:xml-soap-service-management-service"
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<return xmlns:ns2="http://schemas.xmlsoap.org/soap/encoding/"
xsi:type="ns2:Array" ns2:arrayType="xsd:string[1]">
<item xsi:type="xsd:string">urn:datauniversal-com:client</item>
</return>
</ns1:listResponse>

</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

What gets displayed:

Exception in thread "main" [SOAPException: faultCode=SOAP-ENV:Client;
msg=Unable to resolve namespace URI for 'ns2'.;
targetException=java.lang.IllegalArgumentException: Unable to resolve
namespace URI for 'ns2'.]
        at org.apache.soap.rpc.Call.invoke(Call.java, Compiled Code)
        at
org.apache.soap.server.ServiceManagerClient.invokeMethod(ServiceManagerClien
t.java, Compiled Code)
        at
org.apache.soap.server.ServiceManagerClient.list(ServiceManagerClient.java,
Compiled Code)
        at
org.apache.soap.server.ServiceManagerClient.main(ServiceManagerClient.java,
Compiled Code)

Sincerely,
Jay Freeman (saurik)
saurik@saurik.com <ma...@saurik.com>

RE: ServiceManagerClient: Unable to resolve namespace URI for 'ns2'.

Posted by "Jay Freeman (saurik)" <sa...@saurik.com>.
OK, I've been debugging it, and I managed to find the problem.  There is a
bug in Xerces's deferred node instantiation system having to do with setting
the namespace URI for attributes with "xmlns" as the prefix.  I am sending a
patch to the Xerces people now.  Oh, and sorry about the HTML e-mail, I
didn't even realize until hours after I had sent it.

Sincerely,
Jay Freeman (saurik)
saurik@saurik.com <ma...@saurik.com>

-----Original Message-----
From: Jay Freeman (saurik) [mailto:saurik@saurik.com]
Sent: Sunday, February 25, 2001 7:33 AM
To: Soap-User
Subject: ServiceManagerClient: Unable to resolve namespace URI for 'ns2'.

In trying to use ServiceManagerClient, I'm running into an annoying error
message.  I'm working with the latest CVS of xml-soap (although I have
tested that this fails with 2.1 as well) and the latest CVS of xml-xerces
(although an older CVS build from a few weeks ago failed as well).  Anyone
have any idea what is going on?

...

Sincerely,
Jay Freeman (saurik)
saurik@saurik.com <ma...@saurik.com>


RE: ServiceManagerClient: Unable to resolve namespace URI for 'ns2'.

Posted by "Jay Freeman (saurik)" <sa...@saurik.com>.
OK, I've been debugging it, and I managed to find the problem.  There is a
bug in Xerces's deferred node instantiation system having to do with setting
the namespace URI for attributes with "xmlns" as the prefix.  I am sending a
patch to the Xerces people now.  Oh, and sorry about the HTML e-mail, I
didn't even realize until hours after I had sent it.

Sincerely,
Jay Freeman (saurik)
saurik@saurik.com <ma...@saurik.com>

-----Original Message-----
From: Jay Freeman (saurik) [mailto:saurik@saurik.com]
Sent: Sunday, February 25, 2001 7:33 AM
To: Soap-User
Subject: ServiceManagerClient: Unable to resolve namespace URI for 'ns2'.

In trying to use ServiceManagerClient, I'm running into an annoying error
message.  I'm working with the latest CVS of xml-soap (although I have
tested that this fails with 2.1 as well) and the latest CVS of xml-xerces
(although an older CVS build from a few weeks ago failed as well).  Anyone
have any idea what is going on?

...

Sincerely,
Jay Freeman (saurik)
saurik@saurik.com <ma...@saurik.com>