Author |
Message
|
chris boehnke |
Posted: Wed May 09, 2007 9:49 am Post subject: Capturing a copy of the message in a flow before it leaves |
|
|
 Partisan
Joined: 25 Jul 2006 Posts: 369
|
Hi,
In our message flow, I want to use an output node in the middle of the flow to capture a copy of the transformed message before it leaves for JMS.
1. We want to use this capturing only in TEST environment and NOT in PROD and we DONT want to have 2 different flows in TEST and in PROD.
Is it possible to use some node and capture the message based on the environment(TEST & PROD)?. Lets say in TEST the node is going to capture the messages and lands onto a queue and NOT in PROD(we dont to capture the messages in PROD but the test and prod flow should be the same)
Thanks in advance.
Chris |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed May 09, 2007 9:53 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You can use a Filter node to decide, based on BrokerName or a UDP, if you want to hit the output node.
Something like
Filter --true----------->Output--out-->(NextNode in)
--false----------->NextNode-->....
(outputNode out)-|
So the flow either goes Filter-Output-NextNode or just Filter-NextNode. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
marcin.kasinski |
Posted: Wed May 09, 2007 11:07 am Post subject: |
|
|
Sentinel
Joined: 21 Dec 2004 Posts: 850 Location: Poland / Warsaw
|
In my opinion UDP is better option then filter node. _________________ Marcin |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed May 09, 2007 11:15 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
marcin.kasinski wrote: |
In my opinion UDP is better option then filter node. |
Um.
A UDP may be better than using the Broker Name, true. But you still need something in the flow to DECIDE whether to write to output or not.
A filter node is the easiest way - one could also use RouteToLabel and Labels or PROPAGATE TO LABEL or PROPAGATE TO TERMINAL - but the decision still needs to be made and acted on. A UDP can't do that. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
marcin.kasinski |
Posted: Wed May 09, 2007 11:51 am Post subject: |
|
|
Sentinel
Joined: 21 Dec 2004 Posts: 850 Location: Poland / Warsaw
|
Processing message inside flow can be similar.
With UDP and filter I can then use Route to statement.
The most important is what I have to do to deploy new version of flow
With UDP to deploy flow I will have to set UDP only and deploy the same code.
With Filter node I will have to change flow code (if routing is not based on broker name).
In my opinion UDP is more safe.
if routing is based on broker name it is little better, but what if you have more then 2 environment or you have to change broker name.
I hope you uderstand what I mean. _________________ Marcin
Last edited by marcin.kasinski on Wed May 09, 2007 11:53 am; edited 1 time in total |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed May 09, 2007 11:52 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Well, I do.
You just didn't mention using Route To statement...  _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
|