Author |
Message
|
mark.luebinski |
Posted: Mon Jun 25, 2007 5:41 am Post subject: THROW USER EXCEPTION MESSAGE and Windows Event Log |
|
|
Acolyte
Joined: 27 Mar 2006 Posts: 56
|
Dear Masters,
is it possible to use statements like
THROW USER EXCEPTION MESSAGE xxx VALUE...
without to get entries in Windows Event Log?
Our administrators don't like this.
Thank you!!
Mark |
|
Back to top |
|
 |
Vitor |
Posted: Mon Jun 25, 2007 5:53 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Where else would the flow put exception information???
You might want to consider some kind of generic sub flow wired to the Catch terminal of your input node that redirects the output to a more acceptable location. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mark.luebinski |
Posted: Mon Jun 25, 2007 5:55 am Post subject: |
|
|
Acolyte
Joined: 27 Mar 2006 Posts: 56
|
Hi Vitor,
I use Catch-Terminal with subflow already. But I get also a entry in Event Log. (
Mark |
|
Back to top |
|
 |
Vitor |
Posted: Mon Jun 25, 2007 5:59 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Interesting. What does the subflow do with the error, i.e. how does it handle/consume it? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mark.luebinski |
Posted: Mon Jun 25, 2007 6:20 am Post subject: |
|
|
Acolyte
Joined: 27 Mar 2006 Posts: 56
|
It generate a Mail and write in .ERR-Queue with this code
Code: |
SET Environment.Variables.ERR_QUEUE = InputRoot.MQMD.SourceQueue || '.ERR';
SET OutputLocalEnvironment.Destination.MQDestinationList.DestinationData.queueName = Environment.Variables.ERR_QUEUE;
|
(after this Compute-Node is an Out-Node). If it not works (try-catch-Node), then Throws-NODE. And the inputQueue have BC-Threshold = 1 and the same ERR-Queue - for the case, that the code above don't work.
Could it be, that HTTP-Request destroys MQMD.SourceQueue?! |
|
Back to top |
|
 |
Vitor |
Posted: Mon Jun 25, 2007 6:27 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
It certain sounds like this sub-flow is not working and the error's being rethrown - possibly by the throw node you mention. This is not a good node to be using if you don't want errors in the system log....
A more crucial problem may be there's no such field as MQMD.SourceQueue that I'm aware of. Attempting to use a non-existent field is not going to help with handling errors.
I also have to ask - if you're reading data in with an http node, how does the MQMD get populated?? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mark.luebinski |
Posted: Mon Jun 25, 2007 6:36 am Post subject: |
|
|
Acolyte
Joined: 27 Mar 2006 Posts: 56
|
I save MQMD to Environment.Variables.MQMD_Var BEFORE of using HTTP-Request, and after I buid the new Message from scratch using this code
Code: |
SET OutputRoot.Properties.MessageSet = 'I253C8S002001';
SET OutputRoot.Properties.MessageType = 'msg_GYPKMIW';
SET OutputRoot.Properties.MessageFormat = 'CWF';
SET OutputRoot.MQMD = Environment.Variables.MQMD_Var; |
But now I'm goint to try to use a Filter-Node instead of THROW to go to Error-Subflow... I only thought, that it is easy to deactivate writing in Windows Event Log )) |
|
Back to top |
|
 |
Vitor |
Posted: Mon Jun 25, 2007 6:46 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
mark.luebinski wrote: |
I save MQMD to Environment.Variables.MQMD_Var BEFORE of using HTTP-Request, and after I buid the new Message from scratch using this code
|
That's still not going to give you anything called InputRoot.MQMD.SourceQueue out of the box.
And THROW is a perfectly valid way of getting into an error subflow. Just don't use a throw node within the error handling unless you actually want to get back into the default handling, and ensure that any errors the subflow encounters (mqput failures for instance) are properly dealt with via Failure. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|