Author |
Message
|
Nick |
Posted: Wed Jun 06, 2012 12:15 pm Post subject: More question regarding Java Compute node. |
|
|
Newbie
Joined: 07 Mar 2012 Posts: 8
|
Question on propagating multiple messages via JCN. Using a file input node and reading in a file containing multiple messages. In this case each message header has an identical prefix and reading via loop each message is not a problem. I am able to generate a single message to the out terminal but I am at a loss when it comes to setting up the next message and how to create the assembly for all subsequent propagates. As soon as the second instance tries to propagate I get an error indicating "UnknownParserName = 'MQSTR' The message is read via BLOB and as long as I limit output to a single message it works fine. As a basic question, is it possible to generate messages by looping through the file or am I wasting my time trying to do something that the node does not support?
The info center describes multiple propagates but am not sure if it addresses what I am trying to do. All outbound messages go to a queue but all I get is one.
Thanks for all constructive comments  |
|
Back to top |
|
 |
lancelotlinc |
Posted: Wed Jun 06, 2012 12:19 pm Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
mqjeff |
Posted: Wed Jun 06, 2012 12:26 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
lancelotlinc wrote: |
Set the Transaction Mode on the MQOutput node to 'No'. You will then get all your messages. |
I'm quite sure that won't resolve this issue. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Wed Jun 06, 2012 12:30 pm Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
It is possible it could. If Transaction Mode is automatic, and the Input node has determined Transactionality to be effective, every propagate will be held up at the MQOutput node waiting for the transaction to commit. Each propagate will overwrite the values in the MQOutput register. When EOF finally hits, the Input node commits, and the last values in the MQOutput register will commit to the queue.
But I could be wrong. I defer to your wisdom. _________________ http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Jun 06, 2012 12:31 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
lancelotlinc wrote: |
But I could be wrong. I defer to your wisdom. |
The problem appears to be the structure of the logical message tree - for example, the occurrence of an MQMD as the last child. |
|
Back to top |
|
 |
Esa |
Posted: Wed Jun 06, 2012 11:12 pm Post subject: Re: More question regarding Java Compute node. |
|
|
 Grand Master
Joined: 22 May 2008 Posts: 1387 Location: Finland
|
Nick wrote: |
As a basic question, is it possible to generate messages by looping through the file or am I wasting my time trying to do something that the node does not support? |
Of course it's possible. You can reuse the output assembly but you must call clearMessage() for each root message after propagation and create a new one before the next.
It would help if you could post your code.
Nick wrote: |
All outbound messages go to a queue but all I get is one.
|
I think you already have Transaction mode 'No' on the MQOutput node. Otherwise even the single message you managed to propagate would be rolled back when the next one causes an exception. The transaction mode will depend entirely on your business requirements: are you allowed to send some of the messages in the file twice or not. |
|
Back to top |
|
 |
|