Uploaded image for project: 'Axis'
  1. Axis
  2. AXIS-2820

maxOccurs="2" gets converted to maxOccurs="unbound" after WSDL2java

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.4
    • None
    • WSDL processing
    • None
    • windows xp,axis1.4,weblogic8.1

    Description

      I have the below WSDL . The problem here is that WSDL2java does not bother about the MaxOccur .Which means for any value of maxoccur more than 1,it considers as unbound. Is this an error?Are there any fix available for this in axis 1.4.

      For example in the below WSDL empSkills elelement has a maxOccur ="2" ,but WSDL2java converts this as maxOccur=unbound .

      <?xml version="1.0" encoding="UTF-8"?>

      <wsdl:definitions name="EmployeeSearch" targetNamespace="http://myroots.employee.com.in" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ama="http://myroots.employee.com.in">
      <wsdl:types>
      <xsd:schema targetNamespace="http://myroots.employee.com.in">
      <xsd:complexType name="EmployeeInput">
      <xsd:sequence>
      <xsd:element maxOccurs="1" minOccurs="1" name="empId" type="xsd:string" ></xsd:element>
      </xsd:sequence>
      </xsd:complexType>
      <xsd:complexType name="EmployeeDetails">
      <xsd:sequence>
      <xsd:element maxOccurs="1" minOccurs="1" name="empId" type="xsd:string" ></xsd:element>
      <xsd:element maxOccurs="1" minOccurs="1" name="empName" type="xsd:string" ></xsd:element>
      <xsd:element maxOccurs="1" minOccurs="1" name="empDesig" type="xsd:string" ></xsd:element>
      <xsd:element maxOccurs="1" minOccurs="1" name="empOccupation" type="xsd:string" ></xsd:element>
      <xsd:element maxOccurs="2" minOccurs="0" name="empSkills" type="xsd:string" ></xsd:element>
      </xsd:sequence>
      </xsd:complexType>
      </xsd:schema>
      </wsdl:types>
      <wsdl:message name="EmployeeInput">
      <wsdl:part name="EmployeeInput" type="ama:EmployeeInput"/>
      </wsdl:message>
      <wsdl:message name="EmployeeDetails">
      <wsdl:part name="EmployeeDetails" type="ama:EmployeeDetails"/>
      </wsdl:message>
      <wsdl:portType name="EmployeePortType">
      <wsdl:operation name="getEmployeeDetails">
      <wsdl:input message="ama:EmployeeInput"/>
      <wsdl:output message="ama:EmployeeDetails"/>
      </wsdl:operation>
      </wsdl:portType>
      <wsdl:binding name="EmployeeBinding" type="ama:EmployeePortType">
      <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
      <wsdl:operation name="getEmployeeDetails">
      <wsdlsoap:operation soapAction="http://localhost:7001/test/services/EmployeeSearch/GetEmployeeDetails" style="rpc">
      <wsdl:input>
      <wsdlsoap:body parts="EmployeeInput" use="literal"/>
      </wsdl:input>
      <wsdl:output>
      <wsdlsoap:body parts="EmployeeDetails" use="literal"/>
      </wsdl:output>
      </wsdlsoap:operation>
      </wsdl:operation>
      </wsdl:binding>
      <wsdl:service name="EmployeeSearch">
      <wsdl:port binding="ama:EmployeeBinding" name="EmployeeBinding">
      <wsdlsoap:address location="http://localhost:7001/test/services/EmployeeBinding"/>
      </wsdl:port>
      </wsdl:service>
      </wsdl:definitions>

      Attachments

        Activity

          People

            Unassigned Unassigned
            balaji_rags Balaji
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: