cancel
Showing results for 
Search instead for 
Did you mean: 

Loops in BTP workflows

hash47
Explorer
0 Kudos
1,101

How to implement loops in BTP workflows?

View Entire Topic
tobias_breyer
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Sumit, our editor is BPMN compliant, so from the visual side, you can use many BPMN tutorials on the Internet. Also, the "Exclusive Gateway" approach is quite similar to many control flow modeling styles, as the outbound flows from there usual have the meaning "continue" or "leave/stop looping". With respect to the condition, it's like with programming languages: you have to refer to something in the condition that is updated somehow (but usually during the loop cycle), otherwise the loop would not terminate. In workflows, this can mean various things. If the BPMN loop simulates a typical for-loop that just counts the loop iterations, you would increment a counter (using a script task), and the condition would check whether the counter has reached the number of loop iterations required.

SumitKundu
Active Participant
0 Kudos

Thanks @tobias_breyer for the explanation. I am new to BPMN flows. Now I have seen some sample workflows. As far as I understood, there is one flow with 'default' and another flow with a condition going out of the exclusive gateway. If we have to repeat any step or set of steps, we need to simply put the conditioned flow back just before the desired steps.