Personal tools
You are here: Home Products ReactiveWorkflow
Document Actions

ReactiveWorkflow

RSS Feed Category: Workflow — Other products by this author
Enable the workflows in a portal type's chain to interact by triggering each other's automatic transitions. This allows for the construction of complex and modular workflows with parallel execution paths that split and join.

Current release

No stable release available yet.

If you are interested in getting the source code of this project, you can get it from the code repository.

Experimental releases

There are no experimental releases available at the moment.

Project Description

Project resources
==================
 ReactiveWorkflow
==================

Enable the workflows in a portal type's chain to interact by triggering each
other's automatic transitions. This allows for the construction of complex and
modular workflows with parallel execution paths that split and join.

Add a subscriber for your type:

    <subscriber
        for=".my.ContentType
             Products.CMFCore.interfaces.IActionSucceededEvent"
        handler="Products.ReactiveWorkflow.subscriber.trigger_automatic_transitions"
        />

In portal_workflow give your type a comma separated list of workflows, e.g:

  my_workflow, sub_workflow, another_sub_workflow

Construct your sub-workflows so that they start off in a paused state, with an
automatic transition to a started state, guarded by a check on the 'parent'
workflow review state. e.g.:

    python:here.portal_workflow.getInfoFor(here, 'review_state', wf_id='my_workflow') == 'pending'

The parent workflow can then have an automatic or user transition with a guard
checking that the sub workflows have reached a certain state. e.g.:

    python:not [False for wf_id in ['sub_workflow', 'another_sub_workflow'] if here.portal_workflow.getInfoFor(here, 'review_state', wf_id=wf_id) != 'completed']


Notes
-----

I've included a monkey patch to DCWorkflow that prevents automatic transition
from being executed without checking their guards when the "'Manager' role
bypasses guards" option is set.


Licence: Zope Public Licence 2.1

Laurence Rowe  -  #plone/elro  -  http://objectvibe.net/blog
by Laurence Rowe last modified December 20, 2007 - 12:28

For any issues with the web site functionality, please file a ticket.

Please consult the policy on plone.org content if you want your content published on this site.

Servers and hosting by