Issue Type: Bug Bug
Affects Versions: 0.7
Assignee: Unassigned
Components: component-soap
Created: 11/Mar/13 8:57 AM
Description:

Hi,
A NPE is occurring in line #253 of the SY SOAP InboundHandler.java
the proposed patch is as follows :

@@ -262,7 +262,14 @@
}

Part part = parts.get(0);

  • QName expectedPayloadType = part.getElementName();
    +
    + QName expectedPayloadType;
    + if(part.getElementName() != null ) { + expectedPayloadType = part.getElementName(); + }

    else

    { + expectedPayloadType = part.getTypeName(); + }

    +
    String expectedNS = expectedPayloadType.getNamespaceURI();

the justification for why the patch is compliant with standards is as follows :

http://ws-i.org/profiles/basicprofile-1.2-2010-11-09.html#Bindings_and_Parts specifies that :

R2203 An rpc-literal binding in a DESCRIPTION MUST refer, in its wsoap11:body element(s), only to wsdlart element(s) that have been defined using the type attribute.

subsequently, the message declariation in the following wsdl should be valid :
<message name="DeviceManagerPackage_insertAndActivatePackage">
<part name="request" type="tns:insertAndActivatePackageRequest"/>
</message>

paragraph 4.7.15 Namespaces for Children of Part Accessors reports a valid rpc/literal wsdl that contains
<message name="BarMsg">
<part name="BarAccessor" type="foo:fooType"/>
</message>

The problem consists in the fact that method getElementName() works only if the message element was defined as
<message name="GetLastTradePriceInput">
<part name="body" element="sq:TradePriceRequest"/>
</message>

So to extract the QName it is necessary to use the getTypeName() method.

Project: SwitchYard
Priority: Major Major
Reporter: Jeffrey Bride
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira