|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Validate message with or without RCD Node |
« View previous topic :: View next topic » |
Author |
Message
|
siri2083 |
Posted: Fri Feb 04, 2011 9:26 am Post subject: Validate message with or without RCD Node |
|
|
Apprentice
Joined: 16 Apr 2009 Posts: 39
|
Hello,
I am trying to validate the SWIFT message using TDS message set. My flow looks like below.
Mainflow:
MqInputNode--->compute-->XSL transformationnode-->RCD1--->subflow1:
(XMLNS)
subflow1:
Inputterminal -->RCD2--->Compute1--->outputterminal--->ContinueMailflow
ContinueMailflow:
ComputeNode---->RCD3--->MQOutputNode
RCD1 --- Resets the XMLNSC messsage to BLOB
RCD2 --- Rests the BLOB to XML
Compute1-- builds MRM(Copies inputRoot.XML to Outroot.MRM)
RCD3 ---resets MRM to BLOB
Note:
This Main flow is a part of big architecture where it is triggered by another flow and the output of this again input for some other flow.
Problem statement:
In Compute1, i have set messageset,message type and message format properties to OutputRoot. And in node properties, specified the validation propertis as ContentAndvalue and Exception.
When i am trying to validate the message against Message set, its not getting validated or fails when I passes wrong message.
As per my understanding, MRM messages will get validated only when bitstream tries to write to output queue.
In this case message is successfully written to MQOutputNode
is anything wrong with architecture? why validation is not taking place
Please help
 |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Feb 04, 2011 9:45 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
There are a lot of things wrong with this flow design.
For one thing, you don't need any of those RCDs.
You should be using XMLNSC always, and then do a direct mapping to the TDS message set, rather than using an XML physical layer to skip it.
Also, validation only happens if you enable it, and even then it only happens at the level you have enabled it for. |
|
Back to top |
|
 |
siri2083 |
Posted: Fri Feb 04, 2011 11:38 pm Post subject: |
|
|
Apprentice
Joined: 16 Apr 2009 Posts: 39
|
mqjeff, Thank you for ur reply.
I am finally trying to validate the message using ASBITSTRAM function. still facing same problem.
I am confused about the validation occurrs at different node or different funtion
1. When i use Compute node set what ever properties required for validation.
2. Use of RCD, instead of Comute node. set what ever properties required for validation.
3. use of ASBITSTREAM,
DECLARE parseOptions INTEGER BITOR(FolderBitStream, ValidateValue, ValidateContent, ValidateException, ValidateComplete, ValidateFullConstraints);
CREATE LASTCHILD OF OutputRoot DOMAIN('MRM')PARSE (ASBITSTREAM(InputRoot.BLOB.BLOB)
ENCODING InputRoot.MQMD.Encoding
CCSID InputRoot.MQMD.CodedCharSetId
SET InputRoot.Properties.MessageSet
TYPE InputRoot.Properties.MessageType
FORMAT InputRoot.Properties.MessageFormat
OPTIONS parseOptions );
and in the node properties validation is not on.
My confusion here is, In all these scenarios the validation occurs only when bitstream write to output node? or is there any difference.
 |
|
Back to top |
|
 |
kimbert |
Posted: Mon Feb 07, 2011 2:27 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
I'm confused. Please slow down, and take time to explain exactly what you are trying to do.
Quote: |
I am trying to validate the SWIFT message using TDS message set. |
What does 'validate' mean?
Quote: |
I am finally trying to validate the message using ASBITSTRAM function |
Q1: Does that mean that you have thrown away the message flow in your first post and replaced it with a single Compute node?
Q2: Why ASBITSTREAM?
Q3: Did you try mqjeff's suggestion?
Q4:Please explain why you need ASBITSTREAM here:
Code: |
ASBITSTREAM(InputRoot.BLOB.BLOB) |
If you post any more code, please use [code] tags to make it easy to read. |
|
Back to top |
|
 |
siri2083 |
Posted: Mon Feb 14, 2011 5:04 am Post subject: |
|
|
Apprentice
Joined: 16 Apr 2009 Posts: 39
|
Finally found out the issue and could able to fix issue a week back. I am sorry for the lot of confusion and late response.
Here is the actual problem:
MRM messages are not validated as expected in the VALIDATOR sub flow. But fails when another service/ flow validates the same message against its message set.
Reason for not Validation: MRM message will be validated only when bit stream is trying to write to Output node(ex: MQ Output). In this case the MRM message is converted to BLOB before sending it to Output queue. Where the BLOB message will not be validated.
Code: |
CALL CopyMessageHeaders();
DECLARE parseOptions INTEGER BITOR (FolderBitStream,ValidateValue,ValidateContent,ValidateException,ValidateImmediate,ValidateFullConstraints);
DECLARE BITSTREAM BLOB ASBITSTREAM(InputRoot.MRM, InputRoot.MQMD.Encoding,InputRoot.MQMD.CodedCharSetId,InputRoot.Properties.MessageSet,
InputRoot.Properties.MessageType, InputRoot.Properties.MessageFormat);
CREATE LASTCHILD OF OutputRoot DOMAIN('MRM')PARSE (BITSTREAM
ENCODING InputRoot.MQMD.Encoding
CCSID InputRoot.MQMD.CodedCharSetId
SET InputRoot.Properties.MessageSet
TYPE InputRoot.Properties.MessageType
FORMAT InputRoot.Properties.MessageFormat
OPTIONS parseOptions);
|
This code helped me to validate the message in the same sub flow.
Hope this explains in detail.I came back to post the solution so that, if any one have similar issue it can help them. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|