线上客户的webservice接口 提供的接口地址 可以直接curl访问 但通过webservice cxf代码调用却不行
查了看了一下报文 报文中soap:address location 与访问接口地址的 IP出现变化了
生产服务器没法访问 soap:address location 中的IP地址
然后客户提供一个curl post的调用方式
curl --location --request POST 'http://xxxx:8086/runtime//s' \
--header 'Connection: keep-alive' \
--header 'Authorization;' \
--header 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36' \
--header 'Content-Type: text/xml;charset=UTF-8' \
--header 'Accept: */*' \
--header 'Origin: http://10.12.70.37:8066' \
--header 'Referer: http://10.12.70.37:8066/front/' \
--header 'Accept-Language: zh-CN,zh;q=0.9,en;q=0.8' \
--header 'Cookie: lang=zh-CN' \
--data '<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://i.hotent.com/">
<soapenv:Header/>
<soapenv:Body>
<ser:process>
<!--Optional:-->
<operation>NISP</operation>
<!--Optional:-->
<xmlData>
<![CDATA[
<root><taskCode>BPM-</taskCode><status>状态</status></root>
]]>
</xmlData>
</ser:process>
</soapenv:Body>
</soapenv:Envelope>'
最后根据这段curl 做成httpclient的方式进行请求 调用 通过

2526

被折叠的 条评论
为什么被折叠?



