Author |
Message
|
jeevan |
Posted: Mon Dec 11, 2006 4:48 pm Post subject: Domain definition and real msg doesn't match but still works |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
I am developing a error handling subflow. There are only two conditions - failure and success. So, I designed a subflow as follows:
input->Trace ( for failure this requies to log certain info)
input->Trace->Output ( this requires to log certain info and pass the flow for further processing
My main flow is as follows:
MQinput->errorhandlingsubflow->MQOutput
It works fine. But when I tried to test for failure, I changed the actual message from xml( defined domain) to just text. This should fail in my understanding but the log shows that it also followed the output instead. When it fails it should go to Trace and as there is output, should not it stop there? What am I doing wrong?
I would appreciate your help
thanks |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Dec 11, 2006 4:56 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Forgot again to set full parsing on the MQInput Node and to make it go to failure... did ya?  _________________ MQ & Broker admin |
|
Back to top |
|
 |
jeevan |
Posted: Mon Dec 11, 2006 5:12 pm Post subject: |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
I did not understand what do you mean exactly? In MQInut node, I have defined domain Msg domain as 'XML' and MsgFormat also as ' XML'. What else do I need to do to tell it that non xml message are failure?
thanks |
|
Back to top |
|
 |
kirani |
Posted: Mon Dec 11, 2006 5:16 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
Where did you connect your subflow? Is it connected to the "catch" path of the MQInput node? From your post it sounds like it's connected to the "out" terminal of the MQInput node. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
jeevan |
Posted: Mon Dec 11, 2006 5:22 pm Post subject: |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
subflow
input->Trace ( for failure)
Input->Trace->Output ( for success)
in main flow
MQInput->failure to first input of the subflow
MQinput->out to second input of the subflow
should the failure be connected to catch instead of failure terminal?
thanks |
|
Back to top |
|
 |
kirani |
Posted: Mon Dec 11, 2006 5:26 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
It depends on the Transaction Property and Persistency of your input message. Why don't you connect a Trace node to your "catch" terminal and see if you are getting any exception there. It's a good practice to attach a Throw node at the end in your catch path after you've handled/recorded the exception. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
jeevan |
Posted: Mon Dec 11, 2006 5:33 pm Post subject: |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
Kirani,
Thank you for the suggestion. I am beginner of mb application development. Kinda this is my first assignment. My requirement is as I mentioned, just record some info and forget. In case of success, record some info and pass it to MQoutput node for further processing.
My question is why message domain does not match is not this a problem. So whether I catch or process the error or not, but the message not go to the output. Is not this true? Why the message which is not in xml format also goes to out terminal of the MQinput and goes to MQoutput.
However, i will connect catch to Trace and see what happened. |
|
Back to top |
|
 |
kirani |
Posted: Mon Dec 11, 2006 5:48 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
What do you have in your Trace nodes? It sems your Trace node is not parsing the MEssage Tree thats why the exception is not getting generated. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
jeevan |
Posted: Mon Dec 11, 2006 5:55 pm Post subject: |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
The success Trace has the following pattern
${Root.MQMD.MsgId} , ${CURRENT_DATE} ${EXTRACT(HOUR FROM CURRENT_TIMESTAMP)}
:${EXTRACT(MINUTE FROM CURRENT_TIMESTAMP)}
${CAST(CAST(X'0D' AS BLOB) AS CHAR CCSID 437)}
The failure TraceNode has
${Root.MQMD.MsgId}
${ExceptionList} ${ExceptionList.RecoverableException.Text} |
|
Back to top |
|
 |
kirani |
Posted: Mon Dec 11, 2006 6:06 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
since you are not doing anything with your input message in your message flow, it will not be parsed unless you force the parser by printing ${Root} in your Trace node (out path) or by changing your MQInput node properties. Try any of these options and it should work for you. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
jeevan |
Posted: Mon Dec 11, 2006 6:43 pm Post subject: |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
Let me clarify some issues with you:
The purpose of my design is as follows:
Pick up the message. If failure ( due to some reasons) send msg to nowhere but record msgid, and exceptionList into log file.
if success, send it for further processing as well as record MsgId and datestamp into logfile.
My design is as follows:
Main flow
MQInput failure terminal ->input of - errorhandlingsubflow->MQOutput
MQInput out terminal ->input1 of errorhandlingsubflow->MQOutput
The subflow has input as follows:
input: input->Trace ( for failure this requies to log certain info)
input1: input->Trace->Output ( this requires to log certain info and pass the flow for further processing
I have connected failure of MQInput to input and out of MQInput to input1 of errorhandling subflow node.
I use test message as follows:
Test Msg 1
<Message>
<Body>..Hello, world!..</Body>
</Message>
Test Msg 2
00000000 Hello, world!..
the Log file contains same record in both cases:
X'414d51205742524b365f44454641554c401a7e4520001d3b' , 2006-12-11 21
:21
Only the success Trace in subflow has date stamp, that means in both cases the message goes for processing instead of failure and stopping there.
thanks |
|
Back to top |
|
 |
fjb_saper |
Posted: Tue Dec 12, 2006 3:13 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
fjb_saper wrote: |
Forgot again to set full parsing on the MQInput Node and to make it go to failure... did ya?  |
So did you set parsing immediate and full on the MQInput node and how did that change the behavior of your flow???  _________________ MQ & Broker admin |
|
Back to top |
|
 |
|