Hi Peter,
the reason why your absolute path expression doesn't work is that BPELUnit already extracts the payload from the SOAP message before evaluating the assertions. So what your XPath expressions see is the following XML fragment:
<HelloBPELProcessResponse xmlns="http://www.se.uni-
hannover.de/soa08/tutorial/HelloBPELProcess">
<tns:result xmlns:tns="http://www.se.uni-
hannover.de/soa08/tutorial/HelloBPELProcess">Hello Donald</tns:result>
</HelloBPELProcessResponse>
Based on this you should be able to use following expression:
/hel:HelleBPELProcessResponse/hel:result
Daniel
Hi Daniel,
I encountered a problem that is “org.apache.ode.axis2.OdeFault: SOAP body does not contain required part: payload” when I operate the instance “HelloBpelProcess”. Is it because the ode problem? The ode version is 1.3.6 and the HelloBPELProcessArtifacts.wsdl can be accessed correctly.
I have the following BPEL response from the HelloBPELProcess:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault xmlns:java="java:package org.apache.ode.axis2">
<faultcode>java:org.apache.ode.axis2.OdeFault</faultcode>
<faultstring>SOAP body does not contain required part: payload.</faultstring>
<detail>
<Exception>org.apache.ode.axis2.OdeFault: SOAP body does not contain required part: payload.
at org.apache.ode.axis2.ODEService.onAxisMessageExchange(ODEService.java:147)
…
org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.apache.ode.axis2.OdeFault: SOAP body does not contain required part: payload.
at org.apache.ode.axis2.util.SoapMessageConverter.extractSoapBodyParts(SoapMessageConverter.java:404)
at org.apache.ode.axis2.util.SoapMessageConverter.parseSoapRequest(SoapMessageConverter.java:325)
at org.apache.ode.axis2.ODEService.onAxisMessageExchange(ODEService.java:118)
... 29 more
Caused by: java.lang.IllegalArgumentException: SOAP body does not contain required part: payload.
at org.apache.ode.utils.wsdl.Messages.msgSOAPBodyDoesNotContainRequiredPart(Messages.java:146)
... 32 more
</Exception>
</detail>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
Could you please tell me the solution about the problem?
Thank you
Hongwei Zhou
Hi Daniel,
I tried some ways,but it still has not been resolved. The total project has been uploaded to the attachment.
If you have find any ways to slove the problem,please tell me. Thank you very much for your kind help.
Hongwei Zhou