Author |
Message
|
soudhanya |
Posted: Tue Mar 13, 2018 11:49 am Post subject: MQGet Node |
|
|
Novice
Joined: 27 Feb 2017 Posts: 20
|
I am trying to delete message from queue using MQGET node..
Here are the flow details
HttpInput->Compute->MQGET->HttpReply
In my first flow i am trying to retrieve msgid using browseonly option and in second flow im passing msgid to delete that particular message..
SET OutputRoot.MQMD.MsgId = '414d512045534251413031514d2020205aa22b9320abac76';
Did i miss any thing?.. it is throwing excpetion.. Any help?? |
|
Back to top |
|
 |
Vitor |
Posted: Tue Mar 13, 2018 12:04 pm Post subject: Re: MQGet Node |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
soudhanya wrote: |
In my first flow i am trying to retrieve msgid using browseonly option and in second flow im passing msgid to delete that particular message.. |
This sounds like a massively inefficient design.
soudhanya wrote: |
it is throwing excpetion.. Any help?? |
Perhaps if you told us more about the exception. Like the error text. Or which node is throwing the exception. Or what the other flow looks like (you mention 2 and post details of 1).
If you want me to guess, one possible scenario is:
- User A makes HTTP call, obtains message
- User B makes HTTP call, obtains the same message because nothing's read it off.
- User A processes message, calls 2nd flow to delete message
- User B processes message (duplicating whatever results from the message processing), calls 2nd flow to delete message which throws an exception because User A has deleted it already.
Other scenarios from this very odd design are possible. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
soudhanya |
Posted: Tue Mar 13, 2018 12:21 pm Post subject: |
|
|
Novice
Joined: 27 Feb 2017 Posts: 20
|
So.. ok.. It was my bad.. i would be more clear of asking question..
I have 2 operations: Retrieve and Remove
User A makes HTTP call to retrieve the message.. i selected browse only option.
So its only read..in response i am also sending back msgid.
2.Once the first call was success.. User A makes HTTP call to remove the message..using the msgid
Here is the exception:
ExceptionList
RecoverableException
File:CHARACTER:/build/slot1/S800_P/src/DataFlowEngine/ImbDataFlowNode.cpp
Line:INTEGER:1138
Function:CHARACTER:ImbDataFlowNode::createExceptionList
Type:CHARACTER:ComIbmMQGetNode
Name:CHARACTER:Sample1#FCMComposite_1_6
Label:CHARACTER:Sample1.MQ Get
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2230
Text:CHARACTER:Node throwing exception
Insert
Type:INTEGER:14
Text:CHARACTER:Sample1.MQ Get
RecoverableException
File:CHARACTER:/build/slot1/S800_P/src/DataFlowEngine/ImbMqGetNode.cpp
Line:INTEGER:1705
Function:CHARACTER:ImbMqGetNode::failureProcess
Type:CHARACTER:
Name:CHARACTER:
Label:CHARACTER:
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:4633
Text:CHARACTER:MQGet node Exception
RecoverableException
File:CHARACTER:/build/slot1/S800_P/src/DataFlowEngine/ImbMqGetNode.cpp
Line:INTEGER:1964
Function:CHARACTER:ImbMqGetNode::writeMqmd
Type:CHARACTER:ComIbmMQGetNode
Name:CHARACTER:Sample1#FCMComposite_1_6
Label:CHARACTER:Sample1.MQ Get
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:2
Number:INTEGER:5912
Text:CHARACTER:Exception whilst writing field named
Insert
Type:INTEGER:5
Text:CHARACTER:MQMD
Insert
Type:INTEGER:5
Text:CHARACTER:MsgId
Insert
Type:INTEGER:5
Text:CHARACTER:414d512045534251413031514d2020205aa22b9320abac76
RecoverableException
File:CHARACTER:/build/slot1/S800_P/src/CommonServices/ImbValue.cpp
Line:INTEGER:983
Function:CHARACTER:ImbValue::typeError
Type:CHARACTER:
Name:CHARACTER:
Label:CHARACTER:
Catalog:CHARACTER:BIPmsgs
Severity:INTEGER:3
Number:INTEGER:2328
Text:CHARACTER:Wrong type exception
Insert
Type:INTEGER:5
Text:CHARACTER:CHARACTER
Insert
Type:INTEGER:5
Text:CHARACTER:BLOB |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Mar 13, 2018 2:10 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
This tells you all you need to know
Code: |
Text:CHARACTER:Wrong type exception
Insert
Type:INTEGER:5
Text:CHARACTER:CHARACTER
Insert
Type:INTEGER:5
Text:CHARACTER:BLOB |
And check your code. Looks like you forgot a 0x somewhere...
Have fun.  _________________ MQ & Broker admin |
|
Back to top |
|
 |
abhi_thri |
Posted: Wed Mar 14, 2018 1:29 am Post subject: |
|
|
 Knight
Joined: 17 Jul 2017 Posts: 516 Location: UK
|
Code: |
SET OutputRoot.MQMD.MsgId = '414d512045534251413031514d2020205aa22b9320abac76'; |
Are you using the above statement in your code? If so that is assigning char value to MsgId which expects blob instead.
To assign blob use the below one
Code: |
SET OutputRoot.MQMD.MsgId = X'414d512045534251413031514d2020205aa22b9320abac76'; |
|
|
Back to top |
|
 |
Vitor |
Posted: Wed Mar 14, 2018 5:12 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
soudhanya wrote: |
I have 2 operations: Retrieve and Remove
User A makes HTTP call to retrieve the message.. i selected browse only option.
So its only read..in response i am also sending back msgid.
2.Once the first call was success.. User A makes HTTP call to remove the message..using the msgid |
And aside from the comment of my worthy associate, what prevents User B retrieving the same message between these 2 operations? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|