1 Reply Latest reply on Dec 27, 2004 12:55 PM by bluesterror

    document/literal and parameters names

    ebu

      Hi.
      I?ve encountered couple of problems while changed my web services from rpc/encoded to document/literal. The most annoying one is that Axis? Java2WSDL tool generates names for parameters for each method independently, i.e. all methods in a service get their parameters named in0, in1 and so on, which leads to collision . Consider following wsdl:

       <schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://myservice.com">
       <element name="in0" type="tns2:SomeObject"/> <!?For method 1-->
       <element name="in0" type="tns2:EnotherObject"/> <!?For method 2->
       </schema>
      ?
       <wsdl:message name="method1">
       <wsdl:part name="in0" element="impl: in0"/>
       </wsdl:message>
      
       <wsdl:message name="method2">
       <wsdl:part name="in0" element="impl: in0"/>
       </wsdl:message>
      

      I know that axis can retrieve parameter names from endpoint implementation class debugging info, but this does not solves the problem since methods may heave same parameters names throughout the class.
      Also I can?t manage jwsdp?s wscompile to generate wsdl without redundant wrapper type for each method so that MS WSE parser could understand them.

      The only solution I see is to change Java2WSDL?s ServiceDesc.createOperationForMethod
      to add method?s name to the parameter?s name, like this:
      paramDesc.setQName(new QName(opNamespace, method.getName()+"_in" + k));
      



      So, it would be great if somebody could share some info about developing real doc/lit (i.e. something more complex than single-method complexbean sample from dist) service on JBoss.


      wbr, eugen.