|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
AggregateReply timeout issue still..... |
« View previous topic :: View next topic » |
Author |
Message
|
jhotaling |
Posted: Fri Mar 28, 2003 1:32 pm Post subject: AggregateReply timeout issue still..... |
|
|
 Newbie
Joined: 25 Mar 2003 Posts: 7 Location: Maryland
|
Hello Everyone,
Earlier I thought I solved my problem - but I didn't!.
Has anyone experienced a problem with an AggregateReply timeout? I have
received partial number of responses (1 out of an expected 2) and have
gotten the following output from the AggregateReply timeout terminal
(captured in my trace file):
Code: |
2003-03-28 15:34:05.586 -- Post Timeout MSG = (
(0x1000000)Properties = (
(0x3000000)MessageSet = NULL
(0x3000000)MessageType = NULL
(0x3000000)MessageFormat = NULL
(0x3000000)Encoding = NULL
(0x3000000)CodedCharSetId = NULL
(0x3000000)Transactional = UNKNOWN
(0x3000000)Persistence = UNKNOWN
(0x3000000)CreationTime = NULL
(0x3000000)ExpirationTime = NULL
(0x3000000)Priority = NULL
(0x3000000)ReplyIdentifier = NULL
(0x3000000)ReplyProtocol = NULL
(0x3000000)Topic = NULL
)
(0x1000000)ComIbmAggregateReplyBody = (
(0x1000000)DummyReply = (
(0x1000000)Properties = (
(0x3000000)MessageSet = ''
(0x3000000)MessageType = ''
(0x3000000)MessageFormat = ''
(0x3000000)Encoding = 546
(0x3000000)CodedCharSetId = 437
(0x3000000)Transactional = FALSE
(0x3000000)Persistence = FALSE
(0x3000000)CreationTime = NULL
(0x3000000)ExpirationTime = -1
(0x3000000)Priority = 0
(0x3000000)ReplyIdentifier = X'414d51204a5744322020202020202020b9a6843e20002303'
(0x3000000)ReplyProtocol = NULL
(0x3000000)Topic = NULL
)
(0x1000000)MQMD = (
(0x3000000)SourceQueue = ''
(0x3000000)Transactional = FALSE
(0x3000000)Encoding = 546
(0x3000000)CodedCharSetId = 437
(0x3000000)Format = 'MQSTR '
(0x3000000)Version = 2
(0x3000000)Report = 0
(0x3000000)MsgType = 2
(0x3000000)Expiry = -1
(0x3000000)Feedback = 0
(0x3000000)Priority = 0
(0x3000000)Persistence = 0
(0x3000000)MsgId = X'414d51204a5744322020202020202020b9a6843e20002002'
(0x3000000)CorrelId = X'414d51204a5744322020202020202020b9a6843e20002303'
(0x3000000)BackoutCount = 0
(0x3000000)ReplyToQ = ' '
(0x3000000)ReplyToQMgr = 'JWD2 '
(0x3000000)UserIdentifier = 'db2admin '
(0x3000000)AccountingToken = X'0000000000000000000000000000000000000000000000000000000000000000'
(0x3000000)ApplIdentityData = ' '
(0x3000000)PutApplType = 26
(0x3000000)PutApplName = 'JWD2 '
(0x3000000)PutDate = DATE '2003-03-28'
(0x3000000)PutTime = GMTTIME '20:33:35.040'
(0x3000000)ApplOriginData = ' '
(0x3000000)GroupId = X'000000000000000000000000000000000000000000000000'
(0x3000000)MsgSeqNumber = 1
(0x3000000)Offset = 0
(0x3000000)MsgFlags = 0
(0x3000000)OriginalLength = -1
)
(0x1000010)XML = (
(0x1000000)DUMMY_REPLY = (
(0x2000000) = 'Broker Generated Dummy Reply Message '
)
)
)
)
) |
My Compute node code (which works with the "normal" output message) is:
Code: |
DECLARE myReplyRef REFERENCE TO InputRoot.ComIbmAggregateReplyBody.*[];
SET OutputRoot.XML = null;
if myReplyRef IS NULL then ...... |
My reference doesn't work - it is Null. I need to process all the items
under ComIbmAggregateReplyBody in a generic manner (I just take the
responses and slap them all into a consolidated response document.
Any hints would be appreciated! I'm using WMQI 2.1 with MQ 5.3 in W2K.
Thanks! |
|
Back to top |
|
 |
DanielG |
Posted: Sat Mar 29, 2003 3:16 am Post subject: |
|
|
Novice
Joined: 29 Mar 2003 Posts: 13
|
i don't think it's possible to declare a reference to a set of elements (i.e. *[]). you need to specify a single element when declaring your reference variable. consider pointing to the first element and then stepping through the siblings using the move function:
Code: |
DECLARE myReplyRef REFERENCE TO InputRoot.ComIbmAggregateReplyBody.*[1];
WHILE LASTMOVE(myReplyRef) DO
--do something with current ComIbmAggregateReplyBody...
--...
MOVE myReplyRef NEXTSIBLING repeat type name;
END WHILE;
|
(see ESQL reference for exact syntax) |
|
Back to top |
|
 |
jhotaling |
Posted: Mon Mar 31, 2003 8:43 am Post subject: |
|
|
 Newbie
Joined: 25 Mar 2003 Posts: 7 Location: Maryland
|
DanielG,
Thanks for the reply. Actually, it is possible (this code works):
Code: |
--
-- a reference to each folder in the reply. A folder = a system's reply
--
DECLARE replyIndex INTEGER;
SET replyIndex = 1;
DECLARE myReplyRef REFERENCE TO InputRoot.ComIbmAggregateReplyBody.*[];
SET OutputRoot.XML = null;
WHILE LASTMOVE(myReplyRef) = TRUE DO
-- Possible Dummy Reply to prevent a total no-response timeout condition: ignore it!
if myReplyRef.XML.PERSON_RESPONSE IS NULL then
-- continue on, do nothing
else
-- Overlay the MQMD stuff every time - doesn't really matter.
SET OutputRoot.MQMD = myReplyRef.MQMD;
-- Add system replies to the consolidated response
SET OutputRoot.XML.PERSON_CONSOLIDATED_RESPONSE.PERSON_RESPONSE[replyIndex] = myReplyRef.XML.PERSON_RESPONSE;
SET replyIndex = replyIndex + 1;
end if;
MOVE myReplyRef NEXTSIBLING;
END WHILE; |
Your suggestion did solve the timeout issue though. For some reason, the above code will not work with the results of the timeout. So I took your suggestion and in the compute node that processes the timeout results:
Code: |
--
-- a reference to each folder in the reply. A folder = a system's reply
--
DECLARE replyIndex INTEGER;
DECLARE loopIndex INTEGER;
DECLARE howManyResponses INTEGER;
SET replyIndex = 1;
SET loopIndex = 1;
SET howManyResponses = Cardinality(InputRoot.ComIbmAggregateReplyBody.*[]);
SET OutputRoot.XML = null;
while loopIndex <= howManyResponses do
SET OutputRoot.MQMD = InputRoot.ComIbmAggregateReplyBody.*[loopIndex].MQMD;
-- Possible Dummy Reply to prevent a total no-response timeout condition: ignore its data!
if InputRoot.ComIbmAggregateReplyBody.*[loopIndex].XML.PERSON_RESPONSE IS NULL then
-- continue on, do nothing
else
-- Add system replies to the consolidated response
SET OutputRoot.XML.PERSON_CONSOLIDATED_RESPONSE.PERSON_RESPONSE[replyIndex] = InputRoot.ComIbmAggregateReplyBody.*[loopIndex].XML.PERSON_RESPONSE;
SET replyIndex = replyIndex + 1;
end if;
SET loopIndex = loopIndex + 1;
end while;
-- Build a Status for the requestor
if OutputRoot.XML.PERSON_CONSOLIDATED_RESPONSE is NULL then
-- Only the dummy reply was received - no "real" systems replied in the timeout period
Set OutputRoot.XML.PERSON_CONSOLIDATED_RESPONSE.TIMEOUT.NOREPLY = 'The Broker did not receive any responses from the Operational Systems within the timeout period.';
else
-- Some real systems replied, so give a partioal status
Set OutputRoot.XML.PERSON_CONSOLIDATED_RESPONSE.TIMEOUT.PARTIALREPLY = 'The Broker did not receive responses from all Operational Systems within the timeout period.';
end if; |
I am now ready to get back to coding in java!
Thanks again. |
|
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
|
|
|
|