将错误视为
java.lang.RuntimeException: Exception in preInvoke : javax.xml.soap.SOAPException: org.xml.sax.SAXParseException; lineNumber: 6; columnNumber: 47; The value of attribute "arasAML" associated with an element type "tcin:applyAMLInTCInputData" must not contain the '<' character.
我正在SOAP
用户界面中测试我的网络服务,下面是SOAP
请求。
<soapenv:Envelope xmlns:soapenv="schemas.xmlsoap.org/soap/envelope/"; xmlns:tcin="de4.com/Schemas/TCIntgn/2013-05/TCIntegration">; <soapenv:Header/> <soapenv:Body> <tcin:ApplyAMLInTCInput> <tcin:applyAMLInTCInputData arasAML="<XML><REVISIONS><ITEM_REVISION><itemNo>000147</itemNo><type>PDF,DirectModel,MSPowerPointX</type></ITEM_REVISION></REVISIONS></XML>" message="DownloadDatasetFile" > </tcin:applyAMLInTCInputData> </tcin:ApplyAMLInTCInput> </soapenv:Body> </soapenv:Envelope>
获得SOAP
响应如下
<faultstring>java.lang.RuntimeException: Exception in preInvoke : javax.xml.soap.SOAPException: org.xml.sax.SAXParseException; lineNumber: 6; columnNumber: 47; The value of attribute "arasAML" associated with an element type "tcin:applyAMLInTCInputData" must not contain the '<' character.</faultstring>
答案 0 :(得分:0)
如果数据包含特殊字符,则需要对数据进行URL编码或将其放入CDATA块中。和&gt;。