I'm not sure what support Axis has for RPC/Literal (if any), but it seems
to be doing the right thing in this case. By definition, in an RPC/Literal
message, the part names (in your case, SalesOrder) are simply wrappers and
are NOT to be namespace-qualified. Hence you see the xmlns="" which says
that SalesOrder is not
namespace qualified.

Is there a specific reason why you are even trying to do RPC/Literal in the
first place? As far as I know, RPC/Literal support is spotty at best (even
non-existent) in the various toolkits. You should really be doing
doc/literal. And if you need rpc semantics on the server-side, you can take
a look at Axis' "wrapped" style (which is still doc-literal in the
WebServices world).

- Junaid




                                                                           
             Wei Hsu                                                       
             <[EMAIL PROTECTED]                                             
             com>                                                       To 
                                       [EMAIL PROTECTED]             
             04/13/2004 03:11                                           cc 
             PM                                                            
                                                                   Subject 
                                       problem using WSDL2Java on          
             Please respond to         RPC/Literal                         
             [EMAIL PROTECTED]                                             
                  he.org                                                   
                                                                           
                                                                           
                                                                           
                                                                           




Hi all,

I've been trying to run WSDL2Java on my RPC/Literal WSDL, but I keep
running into a seemingly simple problem.  In the WSDL, I've created a
createSalesOrderRequest message as the following:

<wsdl:message name="createSalesOrderRequest">
        <wsdl:part name="SalesOrder" type="n1:SalesOrderWrap"/>
</wsdl:message>

Here, assume n1 belongs to namespace my.example.com and the namespace of
the WSDL is "urn:SalesCreator".

But when I generate the stubs and make call with them, I found out that the
namespace for SalesOrder isn't picked up.  So the body of the SOAP message
becomes

<createSalesOrder xmlns="urn:SalesCreator">
   <SalesOrder xmlns="">

Instead of setting the xmlns for SalesOrder to that of SalesOrderWrap or
even that of the WSDL, WSDL2Java sets it to empty the namespace.  Any idea
why that's the case?

My question is, is there any thing I can add to the WSDL so that the
generated stubs will set the xmlns to something other than the empty ""?  I
know I can manually modify the stubs to insert a value.  However, that
doesn't solve my problem, since I am writing these WSDL files to be used by
other testing tools that also take advantage of axis' WSDL2Java.

Thanks so much!

Wei

Reply via email to