BPMN Editor – Advanced Workflow
What You Will Learn
After finishing this tutorial you will be able to create more advanced Workflows using the PAK Editor. For an introduction to building simple Workflows, please follow this guide Simple Workflow guide.
To complete this guide you need:
Roughly 20 minutes
The PAK Bpmn Editor ( Download )
First let us look into the Workflow Control panel of the PAK Editor. There are various useful tools that PAK provides such as gates, Sub Workflows and grouping. For more information about the gateways look into this guide: Gateway Overview. For a more advanced documentation about Sub Workflows please look at this guide: Sub Workflow.
Now we start with a normal command in the Editor. The command which is used in our example can be any arbitrary command, in our case we want to build a Workflow to copy an issue any number of times. First we start with the command SimpleTextInput.
After that we need multiple more commands to do our task at least once, in our case it should look like this:
This is what one correct run through the process looks like, but we want to do it multiple times! That is why we add the „Counter“ command at the end of the Workflow and from now on we will need gateways.
Next it is time to add a gateway. In our case we need an exclusive gateway to either return to the beginning or finish the process. This works similar to a for-loop in programming languages. For more information about how to implement loops in the PAK executor please refer to the following guide: Example Workflows. In our case it looks like this then:
As you can see we added two exclusive gateways, as we need to either return to the beginning or go to the end node. Now we also need to add conditions to the paths. In our case we want the Workflow to end, when the counter is 0 or smaller. So we do that by clicking on the node and adding the condition in the properties like this:
Additionally, we want to return to the beginning of the Workflow if the counter is equals or greater than 1:
Now the Workflow will run as many times as the user declares it in the beginning and stop after it is done.
The use of the other gateways works in a similar way, that will not be discussed here. For more info look into the gateway docu mentioned above.
Now we want to make our workflow more readable and extendable. In order to do this we can create a Sub Workflow out of the commands between the gateways. For more information about Sub Workflows look into the guide mentioned above. The result looks like this:
This way the Workflow is easier to read and understand. In addition to that it makes it easier to extend the existing Workflow.
To give you some inspiration you can find more existing Workflows here: Example Workflows.