Author |
Message
|
kevinobyrne |
Posted: Tue Jan 08, 2013 3:35 am Post subject: SOAP request throws exception when parsing response |
|
|
 Voyager
Joined: 17 Jul 2007 Posts: 83 Location: Ireland
|
WMB v 7.0.0.2
I'm using the SOAP Request node to call a web service running on WAS. The web service call succeeds (it's saving a pdf in ECM) but broker throws an exception when parsing the response.
The response seems to come back as an attachment (which isn't necessary) and broker complains that the MIME attachment is missing the end boundary. I have captured it with tcpmon.
Broker Exception:
Code: |
....
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.Insert[5].Type=5
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.Insert[5].Text=POST /CMBSpecificWebService/services/CMWebService HTTP/1.1
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.File=F:\build\S700_P\src\WebServices\WSLibrary\ImbSOAPRequestHelper.cpp
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Line=1801
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Function=ImbSOAPRequestHelper::makeSOAPRequest
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Type=
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Name=
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Label=
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Catalog=BIPmsgs
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Severity=3
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Number=3701
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Text=Error Making SOAP JNI Call: Axis2Requester_processResponseMessageSync
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[1].Type=5
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[1].Text=Axis2Requester_processResponseMessageSync
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[2].Type=5
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[2].Text=org.apache.axiom.om.OMException: java.io.IOException: End of Stream, but boundary not found
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[3].Type=5
CanonicalHeader.ActualException.RecoverableException.RecoverableException.RecoverableException.RecoverableException.Insert[3].Text=Frame : 0 org.apache.axiom.om.OMException: java.io.IOException: End of Stream, but boundary not found
@: org.apache.axiom.attachments.impl.PartFactory.createPart(PartFactory.java:172)
@: org.apache.axiom.attachments.Attachments.getPart(Attachments.java:668)
@: org.apache.axiom.attachments.Attachments.getNextPartDataHandler(Attachments.java:586)
@: org.apache.axiom.attachments.Attachments.getDataHandler(Attachments.java:342)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:244)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:146)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:293)
@: com.ibm.broker.axis2.SoapUtilities.createSOAPMessage(SoapUtilities.java:1948)
@: com.ibm.broker.axis2.SoapUtilities.createSOAPMessage(SoapUtilities.java:1873)
@: com.ibm.broker.axis2.Axis2Requester.processResponseMessageSync(Axis2Requester.java:1451)
Frame : 1 java.io.IOException: End of Stream, but boundary not found
@: org.apache.axiom.attachments.BoundaryPushbackInputStream.read(BoundaryPushbackInputStream.java:258)
@: org.apache.axiom.attachments.BoundaryPushbackInputStream.read(BoundaryPushbackInputStream.java:141)
@: org.apache.axiom.attachments.MIMEBodyPartInputStream.read(MIMEBodyPartInputStream.java:101)
@: org.apache.axiom.attachments.impl.PartFactory.readHeaders(PartFactory.java:192)
@: org.apache.axiom.attachments.impl.PartFactory.createPart(PartFactory.java:95)
@: org.apache.axiom.attachments.Attachments.getPart(Attachments.java:668)
@: org.apache.axiom.attachments.Attachments.getNextPartDataHandler(Attachments.java:586)
@: org.apache.axiom.attachments.Attachments.getDataHandler(Attachments.java:342)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:244)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:146)
@: org.apache.axiom.attachments.Attachments.<init>(Attachments.java:293)
@: com.ibm.broker.axis2.SoapUtilities.createSOAPMessage(SoapUtilities.java:1948)
@: com.ibm.broker.axis2.SoapUtilities.createSOAPMessage(SoapUtilities.java:1873)
@: com.ibm.broker.axis2.Axis2Requester.processResponseMessageSync(Axis2Requester.java:1451)
|
Web service response:
Code: |
HTTP/1.1 200 OK
Date: Tue, 08 Jan 2013 11:12:52 GMT
Server: IBM_HTTP_Server
Transfer-Encoding: chunked
Content-Type: multipart/related; boundary=MIMEBoundaryurn_uuid_66AA868CBDF92F18611357643573380; type="application/xop+xml"; start="<0.urn:uuid:66AA868CBDF92F18611357643573381@apache.org>"; start-info="text/xml"; charset=UTF-8
Content-Language: en
320
--MIMEBoundaryurn_uuid_66AA868CBDF92F18611357643573380
content-type: application/xop+xml; charset=UTF-8; type="text/xml";
content-transfer-encoding: binary
content-id: <0.urn:uuid:66AA868CBDF92F18611357643573381@apache.org>
<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Header />
<soapenv:Body>
<CreateItemReply xmlns:tns="http://webservices.mm.ibm.com" xmlns="http://www.ibm.com/xmlns/db2/cm/beans/1.0/schema">
<RequestStatus success="true"></RequestStatus>
<Item URI="http://urlofpdffile" />
</CreateItemReply>
</soapenv:Body>
</soapenv:Envelope>
0
|
The WAS developer tells me that the same web service response can be read by a java application.
Am I correct in thinking that a multipart MIME attachment must have an end boundary?
I assume there's no special configuration needed on a SOAP Request node to handle this kind of response? |
|
Back to top |
|
 |
McueMart |
Posted: Tue Jan 08, 2013 4:04 am Post subject: |
|
|
 Chevalier
Joined: 29 Nov 2011 Posts: 490 Location: UK...somewhere
|
Quote: |
Am I correct in thinking that a multipart MIME attachment must have an end boundary? |
From a quick bit of research I think you are right.
You might also like to upgrade to 7.0.0.5 though just in case (always best to use the latest versions before trying to 'fix' a problem - which might not be a problem at all!) |
|
Back to top |
|
 |
kevinobyrne |
Posted: Thu Jan 10, 2013 3:05 am Post subject: |
|
|
 Voyager
Joined: 17 Jul 2007 Posts: 83 Location: Ireland
|
Actually to clarify, I'm call the IBM Content Manager Web Service (CMWebService, as you can see in the error). The WAS developer is successfully making calls to the same web service with his application. I'm trying to identify whether the issue is in Broker or Content Manager. I've opened a PMR. |
|
Back to top |
|
 |
mqjeff |
Posted: Thu Jan 10, 2013 3:18 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
If nothing else, you can use a regular HTTPrequest node and receive the message as a BLOB and then manually add the trailing mime delimiter....
But it sounds like either the message is being truncated somehow or the message is not being sent correctly in the first place... |
|
Back to top |
|
 |
kevinobyrne |
Posted: Wed Jan 16, 2013 5:35 am Post subject: |
|
|
 Voyager
Joined: 17 Jul 2007 Posts: 83 Location: Ireland
|
Thanks mqjeff,
I have used a HTTPRequest node, cast the response as a char, then substring to get the Reply from the MIME+Soap Envelope and then cast to blob and ASBITSTREAM to turn it into a message tree. |
|
Back to top |
|
 |
|