axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Peter Danielsen" <>
Subject Axis2 codegen handling of WSDL2 message labels
Date Sat, 26 May 2007 17:03:03 GMT

I've been trying to create an Axis2 code generation template
that would use the value of a message's "messageLabel" attribute in
a WSDL2 document.  Unfortunately, that value doesn't appear in the DOM
created by the AxisServiceBasedMultiLanguageEmitter.  I looked into
this a bit and found that the actual value of the message label
is lost in sub-class implementations of the abstract AxisOperation method
  addMessage(AxisMessage, String)
called by WSDL20ToAxisServiceBuilder.createAxisMessage().

It looks like there's an assumption that message label and
message direction are synonymous.

In TwoChannelAxisOperation.addMessage(AxisMessage, String), the
method checks the label against some pre-defined values and then
classifies the message as either an input, output, or fault message.
This doesn't seem correct.  If I'm reading the WSDL2 spec right, the message
exchange pattern defines the label constraints for its messages.
So, it seems like the classification should be based on
AxisMessage.getDirection() and maybe a new method, like "isFault()".
While what's there now may work, it won't if a new MEP is defined.
I think getDirection() should work regardless.

WSDL20ToAxisServiceBuilder.populateOperations exhibits the
assumption in the for loop that iterates over the
InterfaceMessageReferences.  There may be other places, too.

WSDL2's ability to accommodate new, 3rd party MEPs also calls into question
Axis2's practice of mapping MEP strings to constant integer values
throughout the code.  Why not just stick with the MEP strings?

Please let me know if I should open a JIRA for this.

Peter Danielsen

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message