在 Mule 中,我使用的是 SOAP 组件,它接收 XML 格式的 WSDL 文件。之后我想获取 XML 数据。但它显示错误。我在这里使用
#[message.InboundProperties['Subject']]
它显示空值。这是我的 XML 代码
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:out="http://soap.sforce.com/2005/09/outbound" xmlns:urn="urn:sobject.enterprise.soap.sforce.com">
<soapenv:Header/>
<soapenv:Body>
<out:notifications>
<out:OrganizationId>00D9XXXXXXXXXXXx</out:OrganizationId>
<out:ActionId>04k90xxxxxx</out:ActionId>
<out:SessionId>XXXXXXXXXXXXXXX</out:SessionId>
<out:EnterpriseUrl>https://ap1.salesforce.com/services/Soap/c/29.0/00D90000000q0Mc</out:EnterpriseUrl>
<out:PartnerUrl>https://ap1.salesforce.com/services/Soap/u/29.0/00D90000000q0Mc</out:PartnerUrl>
<!--1 to 100 repetitions:-->
<out:Notification>
**<out:Id>?</out:Id>
<out:sObject>
<!--Zero or more repetitions:-->
<urn:fieldsToNull>?</urn:fieldsToNull>
<!--Optional:-->
<urn:Subject>Test</urn:Subject>
</out:sObject>**
</out:Notification>
</out:notifications>
</soapenv:Body>
</soapenv:Envelope>
SOAP 工作正常。 <urn:Subject>Test</urn:Subject>
此 XML 文件中的主题值