OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Example of an XML workflow (and no coding required)

Hi Folks,
Here is an example of an XML workflow. I implemented this workflow without writing a single line of Java (C++, Perl, etc) code. I simply described "what" workflow I wanted, handed it off to a standard tool, and it implemented the workflow (i.e. it orchestrated the movement of the XML document through the various workflow tasks I identified).
Here is a sample XML document that I desire my workflow to be able to process. It contains a bunch of <Para> elements. Each <Para> element has a classification, and the root <Document> element has a classification:
<?xml version="1.0"?>
<Document classification="secret">
    <Para classification="unclassified">
    <Para classification="confidential">
    <Para classification="unclassified">
    <Para classification="secret">
Here is the process for this document:
1. Check that it is syntactically correct (i.e. check that Document is the root element, check that it contains one or more Para elements, check that each element has a classification attribute, check that the classification values are legal). Use XML Schema validation.
2. Apply this security policy rule: no Para may have a classification higher than the Document's classification. Use Schematron.
3. Apply this second security policy rule: check for "dirty words" (i.e. the document does not contain the words "SCRIPT" or "FUNCTION"). Use Schematron.
4. Assign a tracking number to the document:
    - Insert a <TrackingNumber> element into the document.
    - Generate a UUDI and insert it into <TrackingNumber>
Here is a picture showing the workflow:


I described this workflow using XProc (XML Pipeline Language), handed the description off to Calabash (an XProc processor), and Calabash did the rest. I didn't write a single line of Java (C++, Perl, etc) code.

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS