Graph Structure

Since a the set of activities and transitions in a process form a Graph, Graph Theory can be applied to catch several well-known structural problems before a process is ever executed.

Graph Theory: Graph Theory is a branch of mathematics. Fortunately, those parts of graph theory that are relevant to workflow are very simple. Hence, this chapter does not require any prior knowledge of graph theory (a degree in mathematics is definitely not required!). There is a wealth of information about graph theory on the Internet, where further discussion on many of the topics discussed in this chapter can be easily found.

For example: consider a process in which an activity has a transition to another activity, which in turn has a transition back to the first activity. This forms a cycle in the process graph.

If there were no conditions on the transitions, the process would be guaranteed to end up in an infinite loop. These loops are known as informal loops (or 'ad-hoc' loops) and their presence renders several useful structural validations impossible. For this reason (among others), Cúram workflow provides formal constructs for delimiting iterative sections of a process (the loop-begin and loop-end activities). This allows it to detect the presence of ad-hoc loops in processes and prevents such processes from being released.

Code Analogies: Many developers will be familiar with the programming-language GOTO statement and the curly braces commonly used to delimit the start ({) and end (}) of a formal loop.

GOTO is analogous to ad-hoc loops in a workflow. The curly braces are analogous to the formal loop-begin and loop-end activities in a workflow.