You are viewing a plain text version of this content. The canonical link for it is here.
Posted to wsif-user@ws.apache.org by "Ramaswamy, Muthu" <mr...@gers.com> on 2004/02/14 03:40:00 UTC

Namespace problem when Axis provider is used.

Hi All-

I am using Axis Provider. When the envelope is generated and sent to the server, provider puts and extra namespace. It is causing problem to the remote server. 

For example, the following envelope works.

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">       
      <soapenv:Body>           
         <ns1:searchCustomers soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://trial.gers.com/orchlet#TrialSearch#Common#http://trial.gers.com/orchlet#CommonPT">               
            <customer xsi:type="ns2:Customer" xmlns:ns2="http://trial.gers.com">                   
               <firstName xsi:type="xsd:string" xsi:nil="true"/>                   
            </customer>           
         </ns1:searchCustomers>       
      </soapenv:Body>   
   </soapenv:Envelope>

But the Axis provider generates the following envelope, with extra namespace,  when used:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">       
      <soapenv:Body>           
         <ns1:searchCustomers soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://trial.gers.com/orchlet#TrialSearch#Common#http://trial.gers.com/orchlet#CommonPT">               
            <ns1:customer xsi:type="ns2:Customer" xmlns:ns2="http://trial.gers.com">                   
               <firstName xsi:type="xsd:string" xsi:nil="true"/>                   
            </ns1:customer>           
         </ns1:searchCustomers>       
      </soapenv:Body>   
   </soapenv:Envelope>


In the above envelope, the namespace ns1 to the customer element is causing problem. When I remove it, the remote server process the request without problems.  

Any ideas why I extra namepsace is causing problems? Appreciate your input.

-Muthu

Re: Namespace problem when Axis provider is used.

Posted by Simon Solomon <b0...@FDS.com>.



I had opened a bugzilla on this a while back... but I'm not sure if it has
been fixed.
I used a temporary fix which can be found in the following link.

Bugzilla Info
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18520

Original messages
http://marc.theaimsgroup.com/?l=wsif-user&m=104791036727698&w=2
http://marc.theaimsgroup.com/?l=wsif-user&m=105007214532209&w=2


Simon Solomon
ssolomon@fds.com




                                                                           
             "Ramaswamy,                                                   
             Muthu"                                                        
             <mramaswamy@gers.                                          To 
             com>                      <ws...@ws.apache.org>           
                                                                        cc 
             02/13/2004 09:40                                              
             PM                                                    Subject 
                                       Namespace problem when Axis         
                                       provider is used.                   
             Please respond to                                             
             wsif-user@ws.apac                                             
                  he.org                                                   
                                                                           
                                                                           
                                                                           




Hi All-

I am using Axis Provider. When the envelope is generated and sent to the
server, provider puts and extra namespace. It is causing problem to the
remote server.

For example, the following envelope works.

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance">
      <soapenv:Body>
         <ns1:searchCustomers soapenv:encodingStyle="
http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="
http://trial.gers.com/orchlet#TrialSearch#Common#http://trial.gers.com/orchlet#CommonPT
">
            <customer xsi:type="ns2:Customer" xmlns:ns2="
http://trial.gers.com">
               <firstName xsi:type="xsd:string" xsi:nil="true"/>

            </customer>
         </ns1:searchCustomers>
      </soapenv:Body>
   </soapenv:Envelope>

But the Axis provider generates the following envelope, with extra
namespace,  when used:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance">
      <soapenv:Body>
         <ns1:searchCustomers soapenv:encodingStyle="
http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="
http://trial.gers.com/orchlet#TrialSearch#Common#http://trial.gers.com/orchlet#CommonPT
">
            <ns1:customer xsi:type="ns2:Customer" xmlns:ns2="
http://trial.gers.com">
               <firstName xsi:type="xsd:string" xsi:nil="true"/>

            </ns1:customer>
         </ns1:searchCustomers>
      </soapenv:Body>
   </soapenv:Envelope>


In the above envelope, the namespace ns1 to the customer element is causing
problem. When I remove it, the remote server process the request without
problems.

Any ideas why I extra namepsace is causing problems? Appreciate your input.

-Muthu