【发布时间】:2016-11-30 11:51:25
【问题描述】:
我想得到 arg0 的值。 这是我的代码
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sup="http://support.cxf.module.mule.org/">
<soapenv:Header/>
<soapenv:Body>
<sup:invoke name="INVOKE">
<!--Optional:-->
<sup:arg0 name="ARG0">pichon</sup:arg0>
</sup:invoke>
</soapenv:Body>
</soapenv:Envelope>
这就是我试图获得价值的方式:
<logger message="#[xpath3('/*/soapenv:Envelope/soapenv:Body/sup:invoke/sup:arg0',payload, 'NODESET')]" level="INFO" doc:name="Logger"/>
在此之前我声明了这些命名空间:
<mulexml:namespace-manager includeConfigNamespaces="true">
<mulexml:namespace prefix="soapenv" uri="http://schemas.xmlsoap.org/soap/envelope/"/>
<mulexml:namespace prefix="sup" uri="http://support.cxf.module.mule.org/"/>
</mulexml:namespace-manager>
但我不能,我收到了这个错误:
Caused by: org.mule.api.MessagingException: Execution of the expression "xpath3('/*/soapenv:Envelope/soapenv:Body/sup:invoke/sup:arg0',payload, 'NODESET')" failed. (org.mule.api.expression.ExpressionRuntimeException).
我正在使用 mule 3.8 和 anypoint studio 6.1.2 如果有人可以帮助我,我将不胜感激! 谢谢!
【问题讨论】: