[ https://issues.apache.org/jira/browse/AXIS2-4350?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12718599#action_12718599 ]
Oleg Zenzin commented on AXIS2-4350: ------------------------------------ No problem, I'm pretty sure though the problem is methodElement.getParent() instead of methodElement.getFirstElement(), that's why I've attached the message itself. inAxisMessage.isWrapped() worked right in the case of this message, the problem was that code treated methodElement as if it is the child of method element. I've applied this change in the axis2 source code and shipped for our system which is web-services orchestrating system, works perfect. I'm not sure though we use RPC style. I guess some test cases would not heart. Thanks for discussion! > RPCUtil handles wrapped style of SOAP messages wrongly. > -------------------------------------------------------- > > Key: AXIS2-4350 > URL: https://issues.apache.org/jira/browse/AXIS2-4350 > Project: Axis 2.0 (Axis2) > Issue Type: Bug > Components: adb > Affects Versions: 1.5 > Reporter: Oleg Zenzin > > Class > http://svn.apache.org/repos/asf/webservices/axis2/branches/java/1_5/modules/adb/src/org/apache/axis2/rpc/receivers/RPCUtil.java > in the method invokeServiceClass() has following lines: > if (inAxisMessage.isWrapped()) { > objectArray = RPCUtil.processRequest(methodElement, > method, > inMessage.getAxisService().getObjectSupplier()); > } else { > objectArray = RPCUtil.processRequest((OMElement) > methodElement.getParent(), > method, > inMessage.getAxisService().getObjectSupplier()); > } > which wrongly handles the wrapped style of SOAP messages. Like, for instance > this message: > <?xml version='1.0' encoding='UTF-8'?> > <soapenv:Envelope > xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> > <soapenv:Header> > <addr:To > xmlns:addr="http://www.w3.org/2005/08/addressing">http://localhost:8383/bre/services/dtws_tryme_newdecisiontable</addr:To> > > <addr:Action > xmlns:addr="http://www.w3.org/2005/08/addressing">urn:invokeDecisionTable</addr:Action> > > <addr:ReplyTo xmlns:addr="http://www.w3.org/2005/08/addressing"> > > <addr:Address>http://www.w3.org/2005/08/addressing/anonymous</addr:Address> > > </addr:ReplyTo> > <addr:MessageID > xmlns:addr="http://www.w3.org/2005/08/addressing">uuid:53870713-5719-457f-9965-0ebd111e7dda-5</addr:MessageID> > > </soapenv:Header> > <soapenv:Body> > <invokeDecisionTable xmlns="http://newdecisiontable.tryme"> > <ns:param0 xmlns:ns="http://newdecisiontable.tryme"> > <ax25:person xmlns:ax25="http://newdecisiontable.tryme/xsd"> > <ax26:age xmlns:ax26="http://newdecisiontable.tryme/bre" /> > <ax26:greeting > xmlns:ax26="http://newdecisiontable.tryme/bre" /> > <name xmlns="http://newdecisiontable.tryme/bre" > xmlns:ax26="http://newdecisiontable.tryme/bre">Oleg</name> > </ax25:person> > </ns:param0> > </invokeDecisionTable> > </soapenv:Body> > </soapenv:Envelope> > will not be deserialized because BeanUtil.deserialize(methodElement, > parameters, objectSupplier) will be fed with element <soapenv:Body> instead > of element <ns:param0>. > The fix is pretty simple, instead of above code there should be: > if (inAxisMessage.isWrapped()) { > objectArray = > RPCUtil.processRequest(methodElement.getFirstElement(), > method, > inMessage.getAxisService().getObjectSupplier()); > } else { > objectArray = RPCUtil.processRequest(methodElement, > method, > inMessage.getAxisService().getObjectSupplier()); > } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.