DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16097>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16097

xml schema anyType not set in WSDL

           Summary: xml schema anyType not set in WSDL
           Product: Axis
           Version: 1.1beta
          Platform: Other
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: WSDL processing
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


When trying to compile the wrapped wsdl for the following class

public class test
{
  public test() {}
  public void Func(java.lang.Exception m) {}
}

java2WSDL warns that java.lang.Exception will be converted to a xml schema
anyType, but the wsdl file created contains type="tns2:Exception" with tns2
undefined instead.

Expected result: type="xsd:anyType" (since xsd is defined as xml schema in the
wsdl file)


compile log:
------------
Z:\>java org.apache.axis.wsdl.Java2WSDL -y wrapped
-o test.wsdl -l"http://localhost:8080/axis/services/test"; -n urn:test -p"test"
urn:test  test
[WARN] Types - -The class java.lang.Exception is defined in a java or javax
package and cannot be converted into an xml schema type.  An xml schema anyType
will be used to define this class in the wsdl file.

resulting wsdl file:
--------------------
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="urn:test"
xmlns="http://schemas.xmlsoap.org/wsdl/";
xmlns:apachesoap="http://xml.apache.org/xml-soap"; xmlns:impl="urn:test"
xmlns:intf="urn:test" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/";
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";>
 <wsdl:types>
  <schema targetNamespace="urn:test" xmlns="http://www.w3.org/2001/XMLSchema";>
   <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
   <element name="Func">
    <complexType>
     <sequence>
      <element name="in0" type="tns2:Exception"/>
     </sequence>
    </complexType>
   </element>
  </schema>
 </wsdl:types>
   <wsdl:message name="FuncResponse">
   </wsdl:message>
   <wsdl:message name="FuncRequest">
      <wsdl:part element="intf:Func" name="parameters"/>
   </wsdl:message>
   <wsdl:portType name="test">
      <wsdl:operation name="Func" parameterOrder="">
         <wsdl:input message="intf:FuncRequest" name="FuncRequest"/>
         <wsdl:output message="intf:FuncResponse" name="FuncResponse"/>
      </wsdl:operation>
   </wsdl:portType>
   <wsdl:binding name="testSoapBinding" type="intf:test">
      <wsdlsoap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
      <wsdl:operation name="Func">
         <wsdlsoap:operation soapAction=""/>
         <wsdl:input name="FuncRequest">
            <wsdlsoap:body namespace="urn:test" use="literal"/>
         </wsdl:input>
         <wsdl:output name="FuncResponse">
            <wsdlsoap:body namespace="urn:test" use="literal"/>
         </wsdl:output>
      </wsdl:operation>
   </wsdl:binding>
   <wsdl:service name="testService">
      <wsdl:port binding="intf:testSoapBinding" name="test">
         <wsdlsoap:address location="http://localhost:8080/axis/services/test"/>
      </wsdl:port>
   </wsdl:service>
</wsdl:definitions>

Reply via email to