|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
HTTPReply Node Content Length Problem |
« View previous topic :: View next topic » |
Author |
Message
|
kishen |
Posted: Mon Nov 29, 2004 6:28 am Post subject: HTTPReply Node Content Length Problem |
|
|
Newbie
Joined: 29 Nov 2004 Posts: 3
|
Hi,
I am facing problems in sending SOAP message with attachment (as BLOB) as response using HTTPReply Node, when the attachment size exceeds 6KB (approx) in size. It works fine when the attachment size is less than 6KB. The size of the SOAP Message Part is 1495 bytes. Though our actual application design involves many nodes, in order to understand the limitation I have created a simplified message flow as given below
HTTPInput-->Compute-->HTTPReply
Compute Node ESQL is given below
----------------------
CREATE COMPUTE MODULE PollTestFlow_Compute
CREATE FUNCTION Main() RETURNS BOOLEAN
BEGIN
CALL CopyMessageHeaders();
CALL CopyEntireMessage();
RETURN TRUE;
END;
CREATE PROCEDURE CopyMessageHeaders() BEGIN
DECLARE I INTEGER 1;
DECLARE J INTEGER CARDINALITY(InputRoot.*[]);
WHILE I < J DO
SET OutputRoot.*[I] = InputRoot.*[I];
SET I = I + 1;
END WHILE;
END;
CREATE PROCEDURE CopyEntireMessage() BEGIN
SET OutputRoot.BLOB.BLOB = InputRoot.BLOB.BLOB;
SET OutputRoot.HTTPResponseHeader."Content-Type" = OutputRoot.HTTPInputHeader."Content-Type";
SET OutputRoot.HTTPResponseHeader."Content-Length" = OutputRoot.HTTPInputHeader."Content-Length";
END;
END MODULE;
I have 'Checked' the 'Generate Default Headers' check box in the properties of HTTPReply Node
I test this flow by sending SOAP messages (using SAAJ API) with attachments of different size. When the size of the attachment exceeds 6KB then when I extract the attachment using SAAJ it just creates a 6KB Document, which is invalid.
In the above flow (in which I used a 24KB text file), I replaced HTTPReply with HTTPRequest node. In this case I was able to successfully extract the attachment using SAAJ API in a servlet.
Is there any limitation on the Response size in WBI MB?
I am using WBI-MB v5.0.1 CSD04 running in Win 2000 Server.
Any help will be much appreciated
Thanks in Advance
Krishna |
|
Back to top |
|
 |
tdolby |
Posted: Tue Nov 30, 2004 7:43 am Post subject: |
|
|
 Newbie
Joined: 29 Jun 2004 Posts: 8
|
Setting Content-Length in any header using a compute node is not advised - the broker code should set that for you.
Can you put a proxy in the middle of the HTTP traffic, and watch the actual bytes being returned from the broker via HTTP? That would show more information about what exactly is getting sent back - if it's truncated, or something. _________________ Trevor Dolby
IIB Development |
|
Back to top |
|
 |
kishen |
Posted: Thu Dec 02, 2004 9:24 pm Post subject: HTTPReply Node Content Length Problem |
|
|
Newbie
Joined: 29 Nov 2004 Posts: 3
|
Hi
I printed the size of message ( in bytes ) which is entering the first node of the broker ( HTTP input ) and the size of the reply message received from broker . The size of the reply message indicates that the reply message gets truncated when the input message is huge ( say 800 KB ) . Following is the output
12/2/04 20:14:50:672 IST] 19a51673 SystemOut O The TOTAL SIZE OF INPUT TO BROKER 1005566
[12/2/04 20:14:56:172 IST] 19a51673 SystemOut O Calling http://172.20.178.18:7080/PollTestFlow
[12/2/04 20:15:00:891 IST] 19a51673 SystemOut O
[12/2/04 20:15:00:891 IST] 19a51673 SystemOut O reply in my machine is
[12/2/04 20:15:00:891 IST] 19a51673 SystemOut O [12/2/04 20:15:00:906 IST] 19a51673 SystemOut O The TOTAL SIZE OF THE OUTPUT MESSAGE FROM BROKER IS 3612
The input message is a SOAP message with a text file as attachment .I have also printed the content of the reply message. The reply message is
------=_Part_9_125965945.1101998700984
Content-Type: text/xml; charset=utf-8
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.w3.org/2002/12/soap-envelope soap.xsd"><SOAP-ENV:Header/><SOAP-ENV:Body><spi:DCAGW_SPI xmlns:spi="http://www.mit.gov.in/eGov/DCAGateway/schema/SPI" xsi:schemaLocation="http://www.mit.gov.in/eGov/DCAGateway/schema/SPI iis.xsd"><spi:SubmitPoll><DCAGWm:DCAGatewayMessage xmlns:DCAGWm="http://www.mit.gov.in/eGov/DCAGateway/schema/DCAGWM" xsi:schemaLocation="http://www.mit.gov.in/eGov/DCAGateway/schema/DCAGWM DCAGatewayME.xsd"><DCAGWm:EnvelopeVersion>1</DCAGWm:EnvelopeVersion><DCAGWm:Header><DCAGWm:MessageDetails><DCAGWm:Class>QRY_TXN</DCAGWm:Class><DCAGWm:Qualifier>poll</DCAGWm:Qualifier><DCAGWm:Function>submit</DCAGWm:Function><DCAGWm:TransactionID>1113</DCAGWm:TransactionID><DCAGWm:CorrelationID>40</DCAGWm:CorrelationID><DCAGWm:Transformation>XML</DCAGWm:Transformation><DCAGWm:DCAGatewayTimestamp>2004-10-25T13:20:00.000-05:00</DCAGWm:DCAGatewayTimestamp></DCAGWm:MessageDetails><DCAGWm:SenderDetails><DCAGWm:IDAuthentication><DCAGWm:senderID>MYDCA</DCAGWm:senderID><DCAGWm:Authentication><DCAGWm:Method>clear</DCAGWm:Method><DCAGWm:Value>try1</DCAGWm:Value></DCAGWm:Authentication></DCAGWm:IDAuthentication></DCAGWm:SenderDetails></DCAGWm:Header><DCAGWm:DCAGatewayDetails><DCAGWm:Keys/></DCAGWm:DCAGatewayDetails><DCAGWm:Body/></DCAGWm:DCAGatewayMessage></spi:SubmitPoll></spi:DCAGW_SPI></SOAP-ENV:Body></SOAP-ENV:Envelope>
------=_Part_9_125965945.1101998700984
Content-Type: application/txt
Content-Id: LicenseThirdParty.txt
THIRD PARTY LICENSE TERMS AND CONDITIONS, NOTICES AND INFORMATION
The license agreement for this product refers you to this file for details concerning terms and conditions applicable to third party software code included in this product, and for certain notices and other information IBM must provide to you under its license to certain software code. The relevant terms and conditions, notices and other information are provided or referenced below. Please note that any non-English version of the licenses below is unofficial and is provided to you for your convenience only. The English version of the licenses below, provided as part of the English version of this file, is the official version.
Notwithstanding the terms and conditions of any other agreement you may have with IBM or any of its related or affiliated entities (collectively "IBM"), the third party software code identified below are "Excluded Components" and are subject to the following terms and conditions:
- the Excluded Components are provided on an "AS IS" basis;
- IBM DISCLAIMS ANY AND ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS WITH RESPECT TO THE EXCLUDED COMPONENTS, INCLUDING, BUT NOT LIMITED TO, THE WARRANTY OF NON-INFRINGEMENT OR INTERFERENCE AND THE IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE;
- IBM will not be liable to you or indemnify you for any claims related to the Excluded Components; and
- IBM will not be liable for any direct, indirect, incidental, special, exemplary, punitive or consequential damages with respect to the Excluded Components.
====================================================================================================================
WB Licences:
WebSphere Studio Workbench:
CERTAIN COMPONENTS OF THE PROGRAM ARE LICENSED BY IBM UNDER THE COMMON PUBLIC LICENSE (------=_Part_9_125965945.1101998700984--
The message ends here . The line " CERTAIN COMPONENTS OF THE PROGRAM ARE LICENSED BY IBM UNDER THE COMMON PUBLIC LICENSE (" is the last line in reply message . But the message which was sent as input has lot more lines after this line . It looks like that the reply message gets truncated beyond some specific size . |
|
Back to top |
|
 |
kishen |
Posted: Sun Dec 12, 2004 10:05 am Post subject: HTTPReply Node Content Length Problem - Solved |
|
|
Newbie
Joined: 29 Nov 2004 Posts: 3
|
The problem has been solved after re-applying CSD04. My earlier patch update had been unsuccessful (dont know why)
Btw for those of you who might hit upon this problem, WBI 5.0 base version has a 32K restriction for HTTP responses, which has been corrected since CSD02.
Thanks for your response. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|