Uploaded image for project: 'JBoss Web Services'
  1. JBoss Web Services
  2. JBWS-1524

WSTools does not handle more than 2 levels of Class Hierarchy properly

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Obsolete
    • Icon: Major Major
    • None
    • None
    • tools-jaxrpc
    • None

      Consider the following SEI

      package com.intuit.fibcm.service;

      import com.intuit.fibcm.fibcmwsobjects.*;
      import java.rmi.Remote;
      import java.rmi.RemoteException;

      public interface WSTestServiceSEI extends Remote
      {
      public StartSessionResponseDataWS startSession (String input) throws RemoteException;
      }

      Using the following config.xml

      <?xml version="1.0" encoding="UTF-8"?>
      <!-This is the config file used by jbossws to generate a wsdl->
      <configuration>
      <java-wsdl>
      <service name="SampleService" parameter-style="bare" endpoint="com.intuit.fibcm.service.WSTestServiceSEI" />

      <namespaces target-namespace="http://com.ball.wstest"
      type-namespace="http://com.ball.wstest/types"/>

      <mapping file="jaxrpc-mapping.xml"/>
      <webservices servlet-link="WSTestEndpoint"/>
      </java-wsdl>
      </configuration>

      along with the attached Class files defining the hierarchy

      ResponseDataWS --> AdminResponseDataWS --> SessionResponseDataWS --> StartSessionResponseDataWS

      the following wsdl is generated which is wrong:

      <complexType name='AdminResponseDataWS'>
      <complexContent>
      <extension base='tns:ResponseDataWS'>
      <sequence/>
      </extension>
      </complexContent>
      </complexType>
      <complexType name='ResponseDataWS'>
      <sequence>
      <element name='sessionData' nillable='true' type='tns:SessionDataWS'/>
      </sequence>
      </complexType>
      <complexType name='SessionDataWS'>
      <sequence/>
      </complexType>
      <complexType name='SessionResponseDataWS'>
      <complexContent>
      <extension base='tns:AdminResponseDataWS'>
      <sequence>
      <element name='sessionData' nillable='true' type='tns:SessionDataWS'/>
      </sequence>
      </extension>
      </complexContent>
      </complexType>
      </schema>
      <schema targetNamespace='http://com.ball.wstest/types' xmlns='http://www.w3.org/2001/XMLSchema' xmlns:ns1='http://fibcmwsobjects.fibcm.intuit.com/jaws' xmlns:soap11-enc='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://com.ball.wstest/types' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
      <import namespace='http://fibcmwsobjects.fibcm.intuit.com/jaws'/>
      <complexType name='StartSessionResponseDataWS'>
      <complexContent>
      <extension base='ns1:SessionResponseDataWS'>
      <sequence>
      <element name='sessionData' nillable='true' type='ns1:SessionDataWS'/>
      <element name='sessionData' nillable='true' type='ns1:SessionDataWS'/>
      </sequence>
      </extension>
      </complexContent>
      </complexType>

      At the 3rd level of the hierarchy the sessionData is added once, and at the 4th level it is added twice. But the 2nd level is generated correctly without any member elements.

        1. ResponseDataWS.java
          3 kB
        2. AdminResponseDataWS.java
          3 kB
        3. SessionResponseDataWS.java
          3 kB
        4. StartSessionResponseDataWS.java
          3 kB
        5. SessionDataWS.java
          0.1 kB

              darran.lofthouse@redhat.com Darran Lofthouse
              mageshbk_jira Magesh Bojan (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: