ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Error validating XML against XSD using Validate node

Post new topic  Reply to topic
 Error validating XML against XSD using Validate node « View previous topic :: View next topic » 
Author Message
DevNYC1
PostPosted: Mon Feb 25, 2013 8:41 am    Post subject: Error validating XML against XSD using Validate node Reply with quote

Apprentice

Joined: 22 Aug 2012
Posts: 32

I am using XSD to validate my XML message which is produced by the Java Compute Node before it's placed on the Q. I created a MessageSet with the msg definition from the XSD

I used the Validate associated with the above Message Set. I set Domain to XMLNSC, selected "Check Domain" and selected "Check Set" (chose the above Message Set). Validation setting: Validate set to "Content and Value". Failure Action set to "Exception List".

So my flow looks like this (I attached the error subflow to the Catch Node in the first node):
Code:
MQ1-->Java CN-->Route-->Validate-->MQ2   
   \
    \(catch)
  Error Subflow


MQ1 Domain is set to XMLNSC, validation to None. Right now (for testing) my Java CN outputs the same XML that it receives. And I know that the XML I am using for testing validates against this XSD successfully.

The error I get during validation in Validate is (I think it's related to the Properties Settings, not the XML itself): 'Domain, set or type check failed' (CHARACTER)

I attached the Trace Node to the Validate node to capture ${ExceptionList} and I get the same error in the Excepton log. Any thoughts on the underlying cause?
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Feb 25, 2013 8:44 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Is the message set deployed to the same execution group as the running flow?

Can you post the full and complete text of the error message?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
adubya
PostPosted: Mon Feb 25, 2013 8:47 am    Post subject: Reply with quote

Partisan

Joined: 25 Aug 2011
Posts: 377
Location: GU12, UK

Is the message set name specified in the message Properties.MessageSet when entering the Validate node ?
Back to top
View user's profile Send private message Send e-mail
kimbert
PostPosted: Mon Feb 25, 2013 9:01 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

I am not convinced that you understand what the error message is saying. The title of your post suggests that you think this is something to do with XSD validation. It is not.

http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/topic/com.ibm.etools.mft.doc/ac20803_.htm

"If you select the check box, the incoming message is checked against the Set property. If you are using the XMLNSC,DataObject, SOAP, MRM, or IDOC parser and want to check that the incoming message belongs to a particular message model, select Check set and select one of the values from the list of the Set property."

One simple way to make this error go away is to uncheck the 'Check Set' option in the Validate node.
Back to top
View user's profile Send private message
DevNYC1
PostPosted: Mon Feb 25, 2013 9:09 am    Post subject: Reply with quote

Apprentice

Joined: 22 Aug 2012
Posts: 32

All great points - thank you! What I realized I needed to do was to include the Reset Content Descriptor Node after the Route node to reset the message properties (I am resetting all of them and validate XML using this node, it can basically replace the Validate node).

So now my flow looks like this:

MQ1-->JCN-->Route-->Reset Content Desc Node-->MQ2

Now I am getting an XSD validation error (if though I checked using this great site http://www.freeformatter.com/xml-validator-xsd.html) that my XML validates successfully against my XSD.

Here is the error:
Error Code: 5025
Errir desc: /6009/A schema validation error has occurred while parsing the XML document

No detail on what validation fails and where.
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Feb 25, 2013 9:52 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

DevNYC1 wrote:
Here is the error:
Error Code: 5025
Errir desc: /6009/A schema validation error has occurred while parsing the XML document

No detail on what validation fails and where.


That's absolutely everything in the exception tree? I would expect there to be a lot more than that, much of it fairly valueless, but you should be getting much more than just one line.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Feb 26, 2013 1:59 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Your message flow has caught an error, and the only information that you have is the ExceptionList tree. Unfortunately, the ExceptionList tree is meant for machines, not users. It does not give the text of the error message.

Here are some steps that you can take:
- if on Windows, look in Windows Event Viewer. You should find the full text of the error message.
- if on Unix/Linux look in the System Log. You will find the first line of the error message. This not ideal - the other lines can contain very useful information - but it is better than the ExceptionList.
- find the error number ( BIPnnnnE ) in the ExceptionList. Use Google to look up the error in the error catalogue. Most error messages have inserts/parameters that need to be filled in. The values of any inserts/parameters can be found in the ExceptionList.
- use the command line tools to take a debug-level user trace. This will contain the full text of all errors, and will also provide a lot of information about what the message flow is doing.
Back to top
View user's profile Send private message
mayheminMQ
PostPosted: Tue Feb 26, 2013 8:39 am    Post subject: Reply with quote

Voyager

Joined: 04 Sep 2012
Posts: 77
Location: UK beyond the meadows of RocknRoll

Wouldn't it be easier to put the flow in Debug mode and see the full Exception List?

Also the RCD node is not to be used just to validate the format of a message. Its primary use is to change the domain/format of a message from one to another. It may fit the purpose but is not designed for it.

One more way is to view the output of the JCN node and check whether the values in headers for message set/format are set as required.
_________________
A Colorblind man may appear disadvantaged but he always sees more than just colors...
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Feb 26, 2013 9:00 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
Wouldn't it be easier to put the flow in Debug mode and see the full Exception List?
No - that is exactly my point. The exception list is not very useful because it does not quote the text of the error message. I've lost count of the number of users on this forum who say 'I tried X but I got error number BIP????E, what can I do?'. The answers are given in my post above.
Back to top
View user's profile Send private message
DevNYC1
PostPosted: Tue Feb 26, 2013 12:11 pm    Post subject: Reply with quote

Apprentice

Joined: 22 Aug 2012
Posts: 32

Vitor wrote:
DevNYC1 wrote:
Here is the error:
Error Code: 5025
Errir desc: /6009/A schema validation error has occurred while parsing the XML document
No detail on what validation fails and where.


That's absolutely everything in the exception tree? I would expect there to be a lot more than that, much of it fairly valueless, but you should be getting much more than just one line.
You were 100% right - turned out that the error sub-flow I was using only captured the first error. Instead, I used the trace node to capture ${ExceptionList} and specified a file for tracing and was able to see the underlying XSD errors.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Error validating XML against XSD using Validate node
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.