私は添付ファイルでリクエストを送信し、さまざまな情報を持つサーバーからの応答を受け取るWebサービスを使用しています。私は別の質問Adding an attachment to SOAP requestでリクエストを一緒にすることでいくつかの問題を文書化しましたが、このビットは解決されましたが、今や別の問題がレスポンスについています。SOAP形式のSOAPレスポンスWSE
我々はOK応答を受け取るが、エラーを知らせるスローされます。
応答が整形式のXMLではありません。
のInnerExceptionである:
WSE1608:いいえXOP部品を指定コンテンツIDのためのストリームに位置していた:< rootpart*[email protected]。 sun.com >
のようなルックスを返されたXML:
--uuid:36875c60-630c-4e23-9e74-f9a9c7547fc7
Content-Type: application/xop+xml;charset=utf-8;type="text/xml";
Content-ID: <rootpart*[email protected]>
content-transfer-encoding: binary
<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Header xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<payloadManifest xmlns="http://(namespace)">
<manifest contentID="content0" element="ProcessAttachment" namespaceURI="http://(namespace)" version="2.01"/>
</payloadManifest>
</soapenv:Header>
<soapenv:Body>
<tran:ProcessMessageResponse xmlns="http://(namespace)" xmlns:ns2="http://(ns2Namespace)" xmlns:ns3="http://(ns3Namespace)" xmlns:tran="http://(tranNamespace)">
<tran:payload>
<tran:content id="content0">
<s:ShowServiceProcessingAdvisory xmlns:s="http://(sNamespace)">
<s:ApplicationArea>
<s:Sender>
<s:Component>Global Warranty Management</s:Component>
<s:Task>ShowAttachments</s:Task>
<s:CreatorNameCode>Creator</s:CreatorNameCode>
<s:SenderNameCode>GM</s:SenderNameCode>
</s:Sender>
<s:CreationDateTime>2012-01-10T12:58:27Z</s:CreationDateTime>
<s:Destination>
<s:DestinationNameCode>XX</s:DestinationNameCode>
<s:DealerNumber>234567</s:DealerNumber>
<s:DealerCountry>US</s:DealerCountry>
</s:Destination>
</s:ApplicationArea>
<s:DataArea>
<s:Show/>
<s:ServiceProcessingAdvisory>
<s:Header>
<s:SecondaryDealerNumber>253909</s:SecondaryDealerNumber>
<s:Disposition>
<s:RepairOrder>
<s:WarrantyClaim xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="ns2:WarrantyClaimExtended">
<s:OEMClaimNumber>00112233445566778899</s:OEMClaimNumber>
<gwm:Attachment xmlns:gwm="http://(gwmNamespace)">
<gwm:AttachmentId>5678987</gwm:AttachmentId>
<gwm:Filename>14.jpg</gwm:Filename>
</gwm:Attachment>
</s:WarrantyClaim>
</s:RepairOrder>
</s:Disposition>
</s:Header>
</s:ServiceProcessingAdvisory>
</s:DataArea>
</s:ShowServiceProcessingAdvisory>
</tran:content>
</tran:payload>
</tran:ProcessMessageResponse>
</soapenv:Body>
</soapenv:Envelope>
--uuid:36875c60-630c-4e23-9e74-f9a9c7547fc7--
私はこれがMIMEの部分のためにエラーであると仮定していますが、これをどのように扱うべきですか?
これは、SoapUIで返されたのとまったく同じXMLであり、返される期待されるXMLです。また、Webサービスのサードパーティ開発者が作業方法の変更を拒否し、またVS 2005にも依存しているためWCFを使用できないという理由で2つの理由でWSEが必要であると付け加えることがあります私たちにぶら下がっている。
編集:ポストを作成するとき、それは監督だった場合、私が受け取る実際の応答は以下の通りです、私は
HTTP/1.1 200 OK
Date: Mon, 16 Jan 2012 09:44:22 GMT
Server: ACE XML Gateway
Cache-Control: no-cache="Set-Cookie"
Set-Cookie: JSESSIONID=h3LnPTxYdZJ3wp4zFl2GV3BYQ7fZD1p8WbvPgl1Qq95g1F9GQhMC!1396094632; path=/
X-Powered-By: Servlet/2.5 JSP/2.1
Content-Type: multipart/related; type="application/xop+xml"; boundary="uuid:a9a94e4e-5134-4995-8884-dfd4d65b7784"; start="<rootpart*[email protected]>"; start-info="text/xml"
Content-Length: 2296
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
--uuid:a9a94e4e-5134-4995-8884-dfd4d65b7784
Content-Type: application/xop+xml;charset=utf-8;type="text/xml";
Content-ID: <rootpart*a9a94e4e-5134-4995-8884-d[email protected]>
content-transfer-encoding: binary
<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Header xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><payloadManifest xmlns="http://www.starstandards.org/webservices/2005/10/transport"><manifest contentID="content0" element="ProcessAttachment" namespaceURI="http://www.starstandards.org/STAR" version="2.01"/></payloadManifest></soapenv:Header><soapenv:Body><tran:ProcessMessageResponse xmlns="http://www.starstandards.org/STAR" xmlns:ns2="http://www.gm.com/2006/GWM" xmlns:ns3="http://www.starstandards.org/webservices/2005/10/transport" xmlns:tran="http://www.starstandards.org/webservices/2005/10/transport"><tran:payload><tran:content id="content0"><s:ShowServiceProcessingAdvisory xmlns:s="http://www.starstandards.org/STAR"><s:ApplicationArea><s:Sender><s:Component>Global Warranty Management</s:Component><s:Task>ShowAttachments</s:Task><s:CreatorNameCode>General Motors</s:CreatorNameCode><s:SenderNameCode>GM</s:SenderNameCode></s:Sender><s:CreationDateTime>2012-01-16T09:44:24Z</s:CreationDateTime><s:Destination><s:DestinationNameCode>XX</s:DestinationNameCode><s:DealerNumber>253909</s:DealerNumber><s:DealerCountry>US</s:DealerCountry></s:Destination></s:ApplicationArea><s:DataArea><s:Show/><s:ServiceProcessingAdvisory><s:Header><s:SecondaryDealerNumber>253909</s:SecondaryDealerNumber><s:Disposition><s:RepairOrder><s:WarrantyClaim xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="ns2:WarrantyClaimExtended"><s:OEMClaimNumber>001116695583</s:OEMClaimNumber><gwm:Attachment xmlns:gwm="http://www.gm.com/2006/GWM"><gwm:AttachmentId>5677606</gwm:AttachmentId><gwm:Filename>1127.jpg</gwm:Filename></gwm:Attachment></s:WarrantyClaim></s:RepairOrder></s:Disposition></s:Header></s:ServiceProcessingAdvisory></s:DataArea></s:ShowServiceProcessingAdvisory></tran:content></tran:payload></tran:ProcessMessageResponse></soapenv:Body></soapenv:Envelope>
--uuid:a9a94e4e-5134-4995-8884-dfd4d65b7784--
特にHTTP/1.0から完全な応答を表示できますか? –
完全な応答は上記です。 – anothershrubery
問題は解決しましたか?私は同じ問題に直面しています。あなたの学習/発見を共有していただけますか?あらかじめThx。 – Nayan