我想知道如何从soap端点获取请求参数。 更具体地说,我有一个基于http-listener的端点,我通过一个soap客户端调用这个端点,我想获得一个在这个soap请求的主体中发送的值。 下面是技术上的规格..如何从骡子的soap端点获取请求参数?
我用骡子3.8和Anypoint工作室6.1.2
这是我的风景 这里的一部分是我的骡子XML的一部分:
<http:listener-config name="HTTP_Listener_Configuration" host="0.0.0.0" port="8081"
doc:name="HTTP Listener Configuration"/>
<cxf:configuration name="CXF_Configuration" enableMuleSoapHeaders="true" initializeStaticBusInstance="true"
doc:name="CXF Configuration"/>
<ws:consumer-config name="Web_Service_Consumer" service="KarmaService" port="KarmaPort"
serviceAddress="http://localhost:8080/TestingWS/Karma" wsdlLocation="http://localhost:8080/TestingWS/Karma?wsdl" doc:name="Web Service Consumer"/>
<flow name="pichondemonoFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/" doc:name="HTTP"/>
<cxf:proxy-service configuration-ref="CXF_Configuration" payload="body" doc:name="CXF"/>
<set-variable variableName="pichonVar" value="#[message.inboundProperties.'http.query.params'.arg0]"
doc:name="Variable"/>
<choice doc:name="Choice">
.
.
.
.
这里是从了SoapUI客户端的请求:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sup="http://support.cxf.module.mule.org/">
<soapenv:Header/>
<soapenv:Body>
<sup:invoke>
<!--Optional:-->
<sup:arg0>Some value</sup:arg0>
</sup:invoke>
</soapenv:Body>
</soapenv:Envelope>
我也阅读一些有关xpath3但我不知道这是否是百世t解析我的xml请求的方式。 什么是最好的方法?
希望这可以被忽略。
我很感谢有人能帮助我。 在此先感谢!