How to add more than two "AND" Steps to a Workflow

Problem

You want to add more than two parallel AND (or XOR) Steps to a workflow but it's not supported in the GUI.

Cause

This is a limitation of the GUI in CQ 5.2 only, the CQ5Workflow engine itself has no restrictions in the number of parallel AND (or XOR) Steps.

Resolution / Workaround

You can create the corresponding Nodes in CRX directly.

A workflow in CQ5 contains Nodes for the Steps in /etc/workflow/<your workflow>/nodes and for the Transitions in /etc/workflow/<your workflow>/transitions.
Every workflow Step is connected by a Transition with another Step.
To add for example a third parallel AND (or XOR) Step in an existing workflow with two parallel AND (or XOR) Steps you have to add one additional Node for the Step and two Nodes for the Transitions from the AND-Split (or XOR-Split) to the Step and from the Step to the AND-Join (or XOR-Join).

Example:

You have a workflow with following Steps:

  • Start
  • Step 1 (above AND)
  • Step 2 left
  • Step 2 right
  • Step 3 (below AND)
  • End

The Steps, the AND-Split and AND-Join are stored as Nodes in /etc/workflow/<your workflow>/nodes.

  • Start - node0
  • Step 1 (above AND) - node1
  • AND-Split - node4
  • Step 2 left - node5
  • Step 2 right - node6
  • AND-Join - node3
  • Step 3 (below AND) - node7
  • End - node2

The Traisitions are stored as Nodes in /etc/workflow/<your workflow>/transitions

  • node4#node5 - from=node4 (AND-Split), to=node5 (Step 2 left)
  • node5#node3 - from=node5 (Step 2 left), to=node3 (AND-Join)
  • node0#node1 - from=node0 (Start), to=node1 (Step 1)
  • node1#node4 - from=node1 (Step 1), to=node4 (AND-Split)
  • node3#node7 - from=node3 (AND-Join), to=node7 (Step 3)
  • node7#node2 - from=node7 (Step 3), to=node2 (End)
  • node4#node6 - from=node4 (AND-Split), to=node6 (Step 2 right)
  • node6#node3 - from=node6 (Step 2 right), to=node3 (AND-Join)

To add a third parallel AND Step you have to add a Node node8 in /etc/workflow/<your workflow>/nodes and two Nodes node4#node8 (with properties 'from=node4' and 'to=node8') and node8#node3 (with properties 'from=node8' and 'to=node3') in /etc/workflow/<your workflow>/transitions.

Note: This third parallel AND Step is not visible in the GUI, but in the inbox of course...

The described example you can download as package Test WF multiple AND.zip
An example with parallel XOR steps you can find at Example Implementation of a Workflow Process Step.

Applies to

CQ5.2 and CQ5.2.1

Last ned

Last ned

 Adobe

Få hjelp raskere og enklere

Ny bruker?