Blog Stats
  • Posts - 15
  • Articles - 0
  • Comments - 2
  • Trackbacks - 6

 

Biztalk and Schematron

I was playing with idea of using Schematron for Biztalk. It turns out that it could be very powerful tool.

Schematron xslt like language wich allows to verify xml based on xpaths. And this is something xsd can't do.

Taking insipration from brilliant article from Sarvana; I decided to write a receive pipeline component that can validate incoming xmls based on xpaths. If the incoming xml fails the tests then I don't want that to enter the system rather than failing further down the line.My requirement was very simple to check for existence of certain nodes; if they dont' exists then message is invalid.

I've created a disassembler pipeline component which reads the message and fires schematron schema validation. If validation is failed it collects all validation errors and throws exception with it. Also it does the standard xsd based validation.e.g Title of person has to match with its sex if not then not a valid message etc.

Schematron.Net is fantastic set of libraries written to exploit schematron capabilities. I used this to execute schematron schemeas on biztalk schemas.

 


Feedback

# re: Biztalk and Schematron

Gravatar Hi Vishal,
Great article. Is it possible for you to share the sourcecode for the Schematron validation pipeline component?
Also, do you know where I can find some more info on how to create schematron schemas?

Best Regards
Paw 12/4/2008 3:40 AM | Paw

Post a comment





 

 

 

Copyright © Vishal H