axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thomas.che...@ascentialsoftware.com
Subject RE: NameSpace help
Date Tue, 10 Sep 2002 19:12:30 GMT
Sorry, one more try:
I think your problem is not exactly that one. 
In the following case: 

<ns1:validateLogin 
xmlns:ns1="http://www.openuri.org/ <http://www.openuri.org/> "> 
<user xsi:type="xsd:string">sriram</user> 
<pwd xsi:type="xsd:string">somanchi</pwd> 
</ns1:validateLogin> 

validateLogin is in the http://www.openuri.org/ <http://www.openuri.org/>
namespace, but user and pwd are in the current default namespace. 

In the other case: 

<validateLogin xmlns="http://www.openuri.org/ <http://www.openuri.org/> "> 
  <user xsi:type="xsd:string">user</user> 
  <pwd xsi:type="xsd:string">password</pwd> 
</validateLogin> 

validateLogin uase and pwd are all in the http://www.openuri.org/
<http://www.openuri.org/>  namespace as the xmlns="http://www.openuri.org/
<http://www.openuri.org/> " validateLogin attribute is specifying
http://www.openuri.org/ <http://www.openuri.org/>  as the new default
namespace.

I will be surprised that WebLogic ignore completely the namespace or is
having a problem because the namespace declaration does not follow a very
specific pattern.

But I will not be surprised that the SOAP server is having trouble if the
user and pwd element do not belong to the right namespace (which is supposed
to be driven by your WSDL).

Thomas 



-----Original Message----- 
From: eric dunn [mailto:ericjeebusiness@yahoo.com
<mailto:ericjeebusiness@yahoo.com> ] 
Sent: Tuesday, September 10, 2002 2:46 PM 
To: axis-user@xml.apache.org 
Cc: ericjeebusiness@yahoo.com 
Subject: NameSpace help 


Hello, 
   I do not want the ns# prefix apache axis creates 
for a namespace. Is there a way to get rid of it? I 
looked in the source and it doesn't seem likely, no 
matter how you set the namespace, deep in the code it 
uses getPrefix to retrieve ns1. This is all because a 
weblogic webservice doesn't like my prefix there. 

What Apache sends : 
------------------------------ 
<ns1:validateLogin 
xmlns:ns1="http://www.openuri.org/ <http://www.openuri.org/> "> 
<user xsi:type="xsd:string">sriram</user> 
<pwd xsi:type="xsd:string">somanchi</pwd> 
</ns1:validateLogin> 


What weblogic wants : 
------------------------------ 
<validateLogin xmlns="http://www.openuri.org/ <http://www.openuri.org/> "> 
  <user xsi:type="xsd:string">user</user> 
  <pwd xsi:type="xsd:string">password</pwd> 
</validateLogin> 


Is there any way to make a Message with a namespace 
without prefixes? 

Warmest Regards, 
Eric Dunn 



code 
----------------- 

QName operationQN = new 
QName("http://www.openuri.org/ <http://www.openuri.org/> ",
"validateLogin"); 
                call.setOperationName( operationQN ); 


               call.addParameter( "user", XMLType.XSD_STRING,
ParameterMode.IN ); 
               call.addParameter( "pwd", XMLType.XSD_STRING, 
ParameterMode.IN );            
         call.setReturnType( XMLType.XSD_INT );   

return ( (Integer) call.invoke(new Object [] {strLoginID,strPwd} )
).intValue(); 




__________________________________________________ 
Yahoo! - We Remember 
9-11: A tribute to the more than 3,000 lives lost
http://dir.remember.yahoo.com/tribute
<http://dir.remember.yahoo.com/tribute>  


Mime
View raw message