EDDP: Special Processing

The ultimate EDDP [Event Driven Document Processing] feature provided by OpenGroupware Coils is that of Special Processing. By linking EDDP into the power of the OpenGroupware Integration Engine the potential use-cases are almost limitless.

When a document is created in a folder which either has or inherits a specialProcessing object property in the document management name-space the coils.blob.event component will create and queue a work-flow process whose input message is the contents of the document. The specialProcessing property value is an OGo URI which names the work-flow route and provides any additional parameters.

ogo:///myRoute?events=00_created&xattr_bankCode=XX1299

Text 1: OGo URI value indicating a new instance of the work-flow route named myRoute should be created when a new document is created. The work-flow route will have an additional XATTR named bankCode with a value of XX1299.

Care should be taken when using special processing to avoid creating event loops. For example if the creation of a document drives a work-flow which in turn creates documents that route should not create those documents in the same folder hierarchy – otherwise a loop of document creation may occur. Special processing links event based document processing to the open ended flexibility of the OIE work-flow engine – therefore it cannot safe-guard against such conditions. Security may also be a concern – if a work-flow transmits a document to a remote location, prints a document, etc... this may result in the contents of the document being made available beyond the original container's security context.

Special processing can be filtered to specific events using the "events" parameter of the URI. By default special processing will be performed for creation, and changed events1. The value of the "events" parameter may be a comma-separated list of event codes in order to specify multiple events. Due to the previously mentioned potential for processing loops triggering special processing on comment ["10_commented"] actions should be avoided; if special processing is required on the comment action the process itself must implement some mechanism for event de-duplication and loop prevention.

Any parameter in the URI starting with the string "xattr_" will be applied to the created process as an XATTR value where the name of the XATTR is the parameter named with the "xattr_" prefix removed.

In addition to any XATTR values all workflow processes created via special processing will have several object properties in the management name-space which contain information about the source document:

  • sourceDocumentId : The object id of the document entity.
  • sourceDocumentFilename : The file-name of the the document. If a process is created by the creation of a document it is important to remember that potential exists for the document to be subsequently renamed.
  • sourceFolderId : The object id of the folder in which the document exists.
  • sourceDocumentChecksum : Contains the SHA512 check-sum value generated from the content of the document. Check-sum values are potentially distinct for each revision of a document – this will be the value of the check-sum of the document revision which drove the creation of the workflow process.

The values of the object properties in addition to the audit logs of the related entities enable the sequence to be traced backwards for troubleshooting purposes as well as auditor review.

{http://www.opengroupware.us/oie}xattr_bankcode 
fred123
{57c7fc84-3cea-417d-af54-b659eb87a046}sourceDocumentFilename
onenote.ctd
{57c7fc84-3cea-417d-af54-b659eb87a046}sourceDocumentId
111929999
{57c7fc84-3cea-417d-af54-b659eb87a046}sourceFolderId
100731221
{57c7fc84-3cea-417d-af54-b659eb87a046}sourceDocumentChecksum

Text 2: Example object properties of a process created by special processing for a document with object id 111929999 and a file-name of "onenote.ctd". Additionally an XATTR named "bankCode" with a value of "XX1299" was included in the special processing URI.