0
我有一个使用ADB绑定创建的axis2客户端。 这个axis2客户端与一个WCF web服务对话,以MTOM模式发送一个XML附件。 产生的SOAP请求是:axis2 mtom mime边界
POST http://xyz/mtom HTTP/1.1
MIME-Version: 1.0
Content-Type: multipart/related;
type="application/xop+xml";
start="<http://tempuri.org/0>";
boundary="uuid:0daa5c61-46d2-4fe1-9944-097b897367b4+id=1";
start-info="application/soap+xml";
action="http://blahblah/SendData"
Host: myserver.org
Content-Length: 22648
Expect: 100-continue
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
--uuid:0daa5c61-46d2-4fe1-9944-097b897367b4+id=1
Content-ID: <http://tempuri.org/0>
如何使内容传输编码:二进制(下同)内容传输编码:8位?
Content-Transfer-Encoding: binary
Content-Type: application/xop+xml;charset=utf-8;type="application/soap+xml"
<s:Envelope><s:Body><SendData>...</SendData></s:Body></s:Envelope>
--uuid:0daa5c61-46d2-4fe1-9944-097b897367b4+id=1
Content-ID: <http://tempuri.org/1/634789954872318389>
Content-Transfer-Encoding: binary
Content-Type: application/octet-stream
Serialized payload here
--uuid:0daa5c61-46d2-4fe1-9944-097b897367b4+id=1--
而且,我想一个mime_boundary是主要的SOAP信封和第二mime_boundary是附件
感谢您的回复。我不得不使用8位编码,因为WCF Web服务实际上期望它。 –
另外,我在几个论坛上看到了对8位编码的引用。所以,这让我望而生畏。 https://issues.apache.org/jira/browse/AXIS2-2236 –
WCF产生的错误信息是什么? –