axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From axis-...@ws.apache.org
Subject [jira] Commented: (AXIS-1524) Extension and sequence order
Date Tue, 24 Aug 2004 15:21:26 GMT
The following comment has been added to this issue:

     Author: Davin Coleman
    Created: Tue, 24 Aug 2004 8:20 AM
       Body:
I see this problem regardless of whether the complextype is extended or not. Elements in a
complextype are always alphabetically ordered by name.

		<xs:sequence>
			<xs:element name="b" type="B"/>
			<xs:element name="a" type="A"/>
		</xs:sequence>

is always returned as a, b not b, a. This is screwing up clients that are using my WSDL file.
When can this be fixed?

---------------------------------------------------------------------
View this comment:
  http://issues.apache.org/jira/browse/AXIS-1524?page=comments#action_37431

---------------------------------------------------------------------
View the issue:
  http://issues.apache.org/jira/browse/AXIS-1524

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: AXIS-1524
    Summary: Extension and sequence order
       Type: Bug

     Status: Unassigned
   Priority: Major

    Project: Axis
   Versions:
             1.1
             1.2 Beta

   Assignee: 
   Reporter: Timothy Barlotta

    Created: Mon, 23 Aug 2004 6:11 AM
    Updated: Tue, 24 Aug 2004 8:20 AM
Environment: Both Sun Solaris and Windows XP

Description:
I seem to have come across an inconsistency in Axis when dealing with inheritance (or I am
doing something wrong - both valid possibilities).  The WSDL is alphabetically sorted and
so is the SOAP return message, however the SOAP return message does not take inheritance into
effect - this results in the order of the SOAP return message being incorrect.

I wrote two java classes: one is GenericResponse.java and the other SpecificResponse.java.
 SpecificResponse is a subclass of GenericResponse.  For examples sake let's say that GenericResponse.java
has the following:

public long getA()
public long getB()
public long getD()

and SpecificResponse adds:
public long getC()

The relevant section of the wsdd for it looks like this:
	<service name="MyWebService" provider="java:RPC">
		<parameter name="allowedMethods" value="sendMail"/>
		<parameter name="isStatic" value="false"/>
		<parameter name="scope" value="request"/>
		<parameter name="className" value="com.webservice.MyWebService"/>
		<parameter name="wsdlTargetNamespace" value="http://postagestatementwizard.wws"/>
		<beanMapping languageSpecificType="java:com.webservice.GenericResponse" qname="ns33:GenericResponse"
xmlns:ns33="http://data.webservice"/>
		<beanMapping languageSpecificType="java:com.webservice.SpecificResponse" qname="ns34:SpecificResponse"
xmlns:ns34="data.webservice"/>
 	</service>

The resulting WSDL file becomes (relevant section): <complexType name="GenericResponse">
<sequence> <element name="a" type="xsd:long"/> <element name="b" type="xsd:long"/>
<element name="d" type="xsd:long"/> </sequence> </complexType>

<complexType name="SpecificResponse">
<complexContent>
<extension base="tns2:GenericResponse">
<sequence>
<element name="c" type="xsd:long"/>
</sequence>
</extension>
</complexContent>
</complexType>

I would expect the SOAP response message to be in the order of a, b, d, c but it comes back
a, b, c, d.


The relevant SOAP message is:
	<a xsi:type="xsd:long">0</a>
	<b xsi:type="xsd:long">0</b>
 	<c xsi:type="xsd:long">0</c>
	<d xsi:type="xsd:long">0</d>

Is anyone else seeing this?  Is there a better way to accomplish this - using inheritance.
 I have had this problem in 1.1 and 1.2b2.  This does not cause a problem with Axis clients
but does with other toolkits clients (Sun One for example).

I have posted this to both the user and dev mailing lists but have not heard anything back.



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


Mime
View raw message