Procedures
"Routing" is when a Case's State or Task's State changes. When a Task's state changes, it can often start other Tasks it's connected to. The Procedure is built to take the main elements of BPMN 2.0.
Process Split and Process Split Gateway (AND)
A parallel gateway (AKA fork or join) is used when a process can perform multiple branches of operation in parallel.
Both examples below do the same thing. They are just drawn differently.
Split Example A
Split Example B
The idea is that once the task "Ask Girl to Dance" closes, all three tasks "Move Feet", "Move Arms", and "Move Head" will activate in parallel (state In Progress).
Exclusive Split Gateway (OR and XOR)
An exclusive OR, which logicians call XOR, represents a decision to take exactly one path in the flow. More than one path can not be taken – they are mutually exclusive, hence the name. This is the behavior generally assigned to the familiar diamond from flowcharting.
The idea is that a boy asks a girl on a date. If she says YES, he gets money and takes her to the Cinema. Otherwise, if she says NO, he will Play XBOX.
The idea is that the task "FLOW 3_Ask Girl on a Date" has defined two Resolution Codes: YES and NO. You see these Resolution Codes as buttons on the Task Detail page.
If she says YES, then the next tasks are FLOW 3_Get Money and FLOW 3_Go to Cinema.
Otherwise, if she says NO, then the next task is FLOW 3_Play XBOX.
To make an "exclusive" gateway work, there should be only one path for each resolution code (in our example, two paths: YES and NO). Otherwise, it turns into an inclusive workflow.
Inclusive Gateway (resolution code as criteria)
An inclusive OR Gateway specifies that one or more available paths will be taken. They could all be taken, or only one of them.
The idea is that a Gateway can activate multiple tasks that meet the requirement. A flow with No Criteria (no resolution code) is considered a TRUE statement, and will always be activated (FLOW 4_Tell your Best Friend).
If she says YES, then the next tasks are FLOW 4_Get Money and FLOW 4_Go to Cinema plus the No Criteria tasks, FLOW 4_Tell your Best Friend
Otherwise, if she says NO, then the next task is FLOW 4_Play XBOX plus the No Criteria tasks, FLOW 4_Tell your Best Friend
Complex Decision Gateway (rules as criteria)
A complex decision gateway allows for a more expressive decision within a business process. Multiple factors, rules, and analyses can all combine to yield results. The analysis should result in at least one path always being taken.
The idea here is that every decision of whether to activate the next task is based on a Rule, rather than a Resolution Code.
Each potential output of the Decision Diamond has an attached rule that analyzes the results and makes a decision.
In the example below, we use two predefined rules in AppBase intended for QA purposes:
- QA_td_resFailFn: SQL rule function that always returns a NOT OK (0) to route a Task
- QA_td_resPassFn: SQL rule function that always returns an OK (1) to route a Task
The example is rather complex, as you can see, the next task is activated based on the results of the rules. The rule QA_td_resPassFn activate the task FLOW 4_Get Money independently of the Resolution Code of the task FLOW 4_Ask Girl on a Date (NO), so this path is always the path selected.
Join Process (OR)
A JOIN (OR) specifies that one or more of the available paths will be taken. They could all be taken, or only one of them.
The idea in this example is that he will tell his best friends about it either way. The highlighted gateway (FLOW 4_Tell your Best Friend) has the setting Activate When as "At least one input (ANY)", which means that either FLOW 4_Play XBOX or FLOW 4_Go to Movies is the path selected, the task FLOW 4_Tell your Best Friend will be activated.