Author |
Message
|
er_pankajgupta84 |
Posted: Wed Jan 25, 2012 2:43 pm Post subject: Difference between RCD node & Validation node |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
Is there anything "Validation Node" can that "RCD" node can't do?
I am not able to find any difference in info center. |
|
Back to top |
|
 |
Vitor |
Posted: Wed Jan 25, 2012 3:12 pm Post subject: Re: Difference between RCD node & Validation node |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
er_pankajgupta84 wrote: |
Is there anything "Validation Node" can that "RCD" node can't do? |
It can trigger validation. The RCD can't.
er_pankajgupta84 wrote: |
I am not able to find any difference in info center. |
 _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Thu Jan 26, 2012 9:08 am Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
Vitor Can you please elaborate..?
Quote: |
It can trigger validation. The RCD can't.
|
What's the use of Validation property in RCD node.
From Info-Center :
Quote: |
On the Validation tab, set the validation properties if you want the parser to validate the body of messages against the Message set. (If a message is propagated to the Failure terminal of the node, it is not validated.) |
I am reading an xml from the DB.. and want to check whether that confines to the mset structure.
So I can use the RCD node for this task?
Or this thing can only be done using RCD and then validate node? |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jan 26, 2012 9:18 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Ok, perhaps I should have said "doesn't always", not "can't".
The RCD changes the properties of the message tree like an input node sets them and validates the message like an input node would (i.e. according to parse timing and other values). The Validation node takes the existing tree properties and validates according to those unconditionally.
So if you're using an RCD (and I've never had much use for them) you can set validation being mindful of the restrictions. If you simply want to check the message tree according to it's existing settings & be sure that what's coming out of the match terminal is what you expect then use that. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Thu Jan 26, 2012 11:25 am Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
That's what I expect from RCD & Validation node.
So to summaries for the problem I had in hand:
A flow having RCD followed by Validation node doesn't have any added advantage if RCD node's parsing timing & validation property is SET.
It becomes difficult when you are modifying existing production flow and people say RCD wasn't validating sometimes and so we have to put a validation node to do the validation.
A comment from the info-center confuses me -
Quote: |
RCD node does not re-parse the message, but the properties that you set for this node determine how the message is parsed when it is next re-parsed by the message flow.
|
This is not true for Validation? |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jan 26, 2012 11:36 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
er_pankajgupta84 wrote: |
This is not true for Validation? |
 _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
kimbert |
Posted: Fri Jan 27, 2012 2:38 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
The question is a reasonable one from er_pankajgupta84. The difference is:
- setting the Validation property on an RCD node to 'Content and Value' will cause the message tree to be validated the next time it gets written ( whether using an output node or ESQL's ASBITSTREAM or the equivalent Java method ).
- inserting a Validation node causes validation of the message tree to occur immediately, regardless of where it is positioned in the message flow.
So...if the RCD node is positioned immediately before an output node, then adding a Validation node will not change anything. Anywhere else in the flow, adding a Validation node will ensure that the message tree matches the message definition. |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Fri Jan 27, 2012 8:29 am Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
Thanks Kimbert,
This is good to know.
That probably could be reason why people have used both RCD node & validate node to validate message where they are further processing the message.
But I have used RCD node for validation before the Mapping node as well.
and when I looked the flow execution in debug mode.. It alway fail just after the RCD node (if the message is not valid). |
|
Back to top |
|
 |
kimbert |
Posted: Fri Jan 27, 2012 8:34 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
You're right - my reply was not as accurate as it sounded. I said
Quote: |
setting the Validation property on an RCD node to 'Content and Value' will cause the message tree to be validated the next time it gets written |
I should have said ' the next time the message flow needs to parse or write the message'. In your scenario, the Mapping node would have tried to access a field ( under the new parser ) which would have triggered some parsing. Might even have triggered the parsing of the entire message, if Parse Timing was set to 'Immediate'. |
|
Back to top |
|
 |
|