[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
Example of an XML workflow (and no coding required)
- From: "Costello, Roger L." <costello@mitre.org>
- To: "'xml-dev@lists.xml.org'" <xml-dev@lists.xml.org>
- Date: Sun, 19 Apr 2009 11:43:10 -0400
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).
EXAMPLE XML WORKFLOW
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>
<Para classification="confidential">
...
</Para>
<Para classification="unclassified">
...
</Para>
<Para classification="secret">
...
</Para>
</Document>
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:
http://www.xfront.com/XML-document-workflow.gif
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.
Cool!
/Roger
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]