axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tom Jordahl <>
Subject RE: cvs commit: xml-axis/java/src/org/apache/axis/utils axisNLS.p roperties
Date Fri, 02 Aug 2002 17:27:21 GMT
The claim is that the WSDL in the bug was generated by .NET.  So I think we want it to work
this way.
I am going to try and create a C# web service that generates this kind of WSDL to see what
.NET does with it.
Tom Jordahl
-----Original Message-----
From: []
Sent: Friday, August 02, 2002 12:33 PM
Subject: Re: cvs commit: xml-axis/java/src/org/apache/axis/utils

Is this legal WSDL? The JAX-RPC spec says that if a PART name is the same, then it becomes
an inout parameter. It says nothing about the elements of a wrapped complexType. Here is my
comment from version 1.13, where I added the "&& !wrapped" item to the if check:

"If we have

<message name="in"><part name="in" element="e"/></message>
<message name="out"><part name="out" element="e"/></message>

where e contains a string named a. Note that the input and output
messages both refer to the same element. Because the unwrapped list
of parameters are named the same for input and output, we used to say
we had an inout parameter and generate the following:

public void e(StringHolder a);

but inoutness is determined by part name, not parameter name, so we
should generate:

public String e(String a);

This is a TCK issue."

I said this is a TCK issue, but I just ran the TCK with your commit and it worked (they DID
change the doc/lit tests for us, so I think the issue is now just masked). I don't have a
strong feeling about this, so no -1, but it feels wrong to me. I question the legality of
the WSDL in the bugzilla.

Russell Butek

Please respond to 

Subject: cvs commit: xml-axis/java/src/org/apache/axis/utils

tomj        2002/08/02 09:05:57

	Modified:    java/src/org/apache/axis/wsdl/symbolTable
java/test/wsdl/import3/MultiImpIncl/wsdl MultiImp.wsdl
Fix bug 11376 -
WSDL2Java generates invalid stubs when a method has an in/out parameter <>

The logic for defining InOut paramters was getting skipped if the WSDL was
wrapped (i.e. from .NET).  Turn this back on.

In addition, throw an error if we encounter two parts with the same name but
different types.  This is illegal so we shouldn't let it slide.

Fix one of our test cases which had this bad WSDL in it.

Revision  Changes    Path
1.19      +8 -5      xml-axis/java/src/org/apache/axis/wsdl/symbolTable/

RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/wsdl/symbolTable/,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- 2 Aug 2002 12:55:33 -0000 1.18
+++ 2 Aug 2002 16:05:57 -0000 1.19
@@ -1114,7 +1114,7 @@ 

	int index,
int outdex,
Parameters parameters,

	-                              boolean trimInput) {
+                              boolean trimInput) throws IOException { 

	Parameter p = (Parameter)inputs.get(index);
// If this is an element, we want the XML to reflect the element name
// not the part name.

	@@ -1131,9 +1131,7 @@
// At this point we know the name and type of the parameter, and that it's at least an
// in parameter.  Now check to see whether it's also in the outputs Vector.  If it is,
// then it's an inout parameter.
-        // Don't bother doing this if the parameters are wrapped since their
-        // names won't be the part names.
-        if (outdex >= 0 && !wrapped) {
+        if (outdex >= 0) { 

	Parameter outParam = (Parameter)outputs.get(outdex);
if (p.getType().equals(outParam.getType())) {

@@ -1143,7 +1141,12 @@ 

	// If we're here, we have both an input and an output
// part with the same name but different types.... guess
// it's not really an inout....

	-                ++parameters.inputs;  // Is this OK??
+                throw new IOException(JavaUtils.getMessage("differentTypes00",
+                     new String[] { p.getName(),
+                                    p.getType().getQName().toString(),
+                                    outParam.getType().getQName().toString()
+                                   }
+                )); 

} else { 


	1.2       +2 -2      xml-axis/java/test/wsdl/import3/MultiImpIncl/wsdl/MultiImp.wsdl

Index: MultiImp.wsdl
RCS file: /home/cvs/xml-axis/java/test/wsdl/import3/MultiImpIncl/wsdl/MultiImp.wsdl,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- MultiImp.wsdl 26 Jul 2002 15:48:27 -0000 1.1
+++ MultiImp.wsdl 2 Aug 2002 16:05:57 -0000 1.2
@@ -17,12 +17,12 @@

	<message name="DataRequestMessage">
<part name="header" element="ses:Session"/>

	-    <part name="body" element="cmp:DataRequest"/>
+    <part name="bodyin" element="cmp:DataRequest"/> 


<message name="DataResponseMessage">
<part name="header" element="ses:Session"/>

	-    <part name="body" element="cmp:DataRequestResponse"/>
+    <part name="bodyout" element="cmp:DataRequestResponse"/> 


<portType name="multiImpInclDataPortType">

	1.33      +1 -0      xml-axis/java/src/org/apache/axis/utils/

RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/utils/,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- 1 Aug 2002 22:13:09 -0000 1.32
+++ 2 Aug 2002 16:05:57 -0000 1.33
@@ -953,4 +953,5 @@
wrongNamespace00=The XML Schema type ''{0}'' is not valid in the Schema version ''{1}''.

onlyOneBodyFor12=Only one body allowed for SOAP 1.2 RPC
+differentTypes00=Error: The input and output parameter have the same name, ''{0}'', but are
defined with type ''{1}'' and also with type ''{2}''.

View raw message