Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Is it possible to create a loop in automation to create a number of tasks

Ward Schwillens_ Schwillie July 10, 2024

Hi there!

A question: 

Is it possible to create a loop in an automation that runs until a condition is met? 

I need something resembling a do ... while or do ... until logic, probably with a fail safe, as we do not want the rule creating kazillions of issues! 😁

I would like to be able to use that feature to create a number of "Dummy" tasks as child issues within an epic.

Thank you for your insights!

2 answers

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 10, 2024

Hi @Ward Schwillens_ Schwillie 

What problem are you solving by creating those "dummy" tasks?  That is, "why do this?"  Knowing that may help the community to offer better suggestions.

Until we know that...

Any mistakes in such looping rules can have consequences.  For example...

  1. a simple rule mistake could halt all rule executions for your site for the rest of the month by consuming the automation limits for your licenses
  2. long running rules could exceed the service limits, halting all rule execution for several hours
  3. self-triggering rules may encounter the service limit for looping, and so halt that specific rule (i.e., 10 loops)

 

What version of Jira are you using (i.e., Cloud, Server, or Data Center), and if Cloud, have you considered your license level and products?

I ask those things because a webhook-based approach (as suggested by Mikael) can allow recursive looping to solve some scenarios, and potentially encounter items #1 and #3 above.

Another approach is to use a single rule with an advanced branch, driven by the contents of a list from a created variable.  This would allow up to 100 items / issues.  This type of rule could encounter items #1 and #2 from above.

 

Kind regards,
Bill

0 votes
Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
July 10, 2024

Yes, that is possible, have a look at this article that describe how you can create a dynamic looping in an automation.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events