Round 2: repeat a step with a BPMN loop
Some work is not done on the first try. A document goes back for rework, a quote needs a second version, a test fails and runs again. In BPMN this is a loop: the same step runs again until the result is right.
Flower BPM gives you two ways to model it. Both reopen the same Jira work item for every round, so the history of all rounds stays in one place:
- a loop marker with a loop condition on the task, compact and without extra elements;
- a gateway with a flow back to the task, which shows the decision in the diagram.
Reference: BPMN Markers describes the loop marker in Flower BPM with all its options, and what the other markers do.
How the loop marker works
The loop marker is the small circular arrow at the bottom of a task. In Flower BPM it runs on a task without a type, a user task, a manual task, and an automated task with Wait for Jira Automation.
- The process reaches the task, and Flower creates its work item as usual.
- A person resolves the work item.
- Flower checks the loop condition. If it is true, Flower reopens the same work item and writes the comment Round 2 of … on it. If it is false, the process goes on.
By default, Flower checks the condition after each round, so the task runs at least once.
To reopen a work item, Flower uses the first transition without a screen into a status of the category To Do, or else In Progress. Your Jira workflow must offer such a transition back from the done status. If it does not, the process instance gets an error comment. See A Task That Runs Again.
Add a loop to a task
Give the task the loop marker
In the Flower modeler, select the task and click the wrench (Change element) in its context pad. The Loop symbol at the top of the menu switches the loop marker on and off. Then the properties panel shows the loop fields: the condition, Test before and Loop maximum.
Choose when it runs again
In the properties panel, open the group Loop and check the statuses or resolutions that mean “once more”, for example the resolution Needs rework. One value of each list must fit. If you check values in both lists, both must fit. The lists work as on a sequence flow, see Gateway Decision Handling.
Or write a loop condition
When nothing is checked, Flower uses the Loop condition, an expression. For example, ${cur.fields.resolution != 'Done'} runs the task again until its work item is resolved as Done.
Set a limit
Optional: Loop maximum stops the loop after that many rounds. Test before checks the condition before the task instead of after it, so the task may not run at all.
Publish
Publish the model and start a process instance.

A loop marker without a condition runs the task once. The validator warns about it, so you see the missing condition before you publish.
What you see in Jira
A reviewer resolves the work item Revise the document with the resolution Needs rework. The work item goes back to an open status, keeps its assignee, and gets the comment Round 2 of …. The author works on it again in the same work item. When the reviewer resolves it as Done, the process goes on. Flower counts the rounds at the process instance (flower.rounds).
Loop marker or gateway with a flow back?
A gateway after the step and a sequence flow back to it give the same result: Flower reopens the work item of the task. The difference is what the reader of the diagram sees.
| Loop marker | Gateway with a flow back | |
|---|---|---|
| In the diagram | One task with a small arrow | A gateway, its conditions and the way back |
| Who decides | Hidden in the loop condition | Visible, for example a separate task Review by another person |
| Steps in between | None: the same task runs again | Any steps between the gateway and the task |
| Best for | A step that one person repeats until it is right | A decision that matters, with a review or an approval |
The loop marker is compact, but it hides the decision. When the reader should see who decides and what happens in between, use the gateway.
Limits
- Only tasks loop. A loop marker on an embedded sub-process or a call activity runs once, and the validator warns.
- No loop back into a call activity. A flow back into a call activity does not start its sub-process again. Flower writes an error comment instead. Put the loop inside the called model, see Known Issues.
- A parallel join after a loop. When a loop with a gateway sits in one branch of a parallel split, the join can continue too early. See Known Issues for the workaround.
Once per item of a list
A loop repeats until a condition is met. Running a step once per item of a list, for example one approval per person in the field Approvers, is a multi-instance activity in BPMN. Flower BPM does not execute the multi-instance marker: a task with it runs once and creates one work item, and the validator warns.
You get the same result with an automated task and two Jira Automation rules:
- An automated task, for example Collect approvals, starts the first rule and waits.
- The first rule creates one sub-task per person with the branch For each.
- The second rule runs when a sub-task is resolved. When all sub-tasks are resolved, it reports the automated task done, with a result such as approved or rejected.
- A gateway after the automated task decides with the result.
The rules, the variant one after another, and the variant with a whole process per item are in Once per Item of a List. For a fixed, small number of items, a parallel gateway with one task per item is simpler.
Frequently asked questions
Does Flower create a new work item for every round?
No. Flower reopens the same work item and writes the comment Round 2 of …, Round 3 of … on it. One task, one work item.
How do I stop a loop that never ends?
Set Loop maximum in the group Loop of the task. Flower stops the loop after that many rounds, and the process goes on.
Why is the work item not reopened?
The Jira workflow needs a transition without a screen from the done status back to an open status. Without it, the process instance gets an error comment.
Read more
- BPMN Markers: the loop marker, multi-instance, and how to get each result in Flower BPM.
- Gateway Decision Handling: conditions on sequence flows, also for loops with a gateway.
- Let a rule do a task: the automated task behind the “once per item” pattern.
- BPMN Flows: sequence flows and loops in the BPMN standard.

