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

Advise for Cascading automation to avoid Loop action

Duc Thang TRAN
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.
January 23, 2025

 

 

Hello everyone,
I’m seeking advice from the community regarding my situation.

I have a list of tickets that are linked in a cascading sequence. For example:

  • Ticket 1 is linked to Ticket 2
  • Ticket 2 is linked to Ticket 3, and so on.

Initially, all tickets have their own estimates, while their start and end dates are empty.

2025-01-23 10_05_11-Window.png

Here’s how my automation works:

  1. When a start date is added to a ticket, the automation calculates the due date as:
    Due Date = Start Date + Original Estimate
  2. For any linked issue, the automation copies the due date from the trigger issue to the start date of the linked issue.

 

To achieve this, I’ve enabled the option:
"Check to allow other rule actions to trigger this rule. Only enable this if you need this rule to execute in response to another rule."

The problem I’m facing is that the loop security limit stops my automation after 10 actions, preventing it from fully executing the chain.

Do you have any ideas or workarounds for this issue?

Thanks in advance for your help!

 

2025-01-23 10_04_36-Window.png

1 answer

1 accepted

1 vote
Answer accepted
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.
January 23, 2025

Hi @Duc Thang TRAN 

 

Short answer: try a scheduled trigger rule as described at the end of this post.

 

Next, please note well some disclaimers:

  • Automation rules attempting to re-implement features of purpose-built, project management tools rarely work well.  They often cannot handle edge cases, and if the automation rules do not run, it creates a mess which may not be easily corrected.  Reasons rules may not run include: rule-writer errors, other rules cause service limit violations, or an Atlassian outage happens. (i.e., Based on my observations, after return to service from an outage, some rules that did not run during an outage will not run as expected: the events appear not to be stored in a way to allow "catching up".)
  • Bypassing service limits with rule workarounds is risky, and could lead to other service / usage limit problems or difficult conversations with your Jira Site Admin and staff manager if Atlassian suspends your account's automation for the site.

 

With those out of the way...

The least risky way to solve this need is not using automation rules, and instead investigating marketplace or Jira features purpose built for such date shifting.  I have no experience with those for Jira Cloud so please check the Atlassian Marketplace for details.

 

Automation workarounds depend upon when one wants the dates updated:

  • Updated close to when the Start Date (or time tracking) change: recursive rule
    • I have never experimented with this approach because I do not want to risk my rules being disabled for a day / month / etc.
    • Use an initial rule to detect the field change, and then use the Send Web Request action to trigger a second rule with an Incoming Webhook Trigger, passing the issue data to the second rule
    • The second rule is recursive to walk the issue chain, repeatedly passing issues as more links are found
    • Disable the "Allow Rule Trigger" option in both rules
    • It is not documented or clear if the 10 loop limit applies for the Incoming Webhook Trigger, so these rules could halt also
  • Updated at least daily / hourly: scheduled trigger rule and a semaphore / indicator
    • Using a first rule trigged on a change to Start Date (or time tracking) set an indicator "flag" in the issue, such as with a custom field or entity property
    • Using a second Scheduled trigger rule with JQL to detect the indicator set above...
      • Clear the indicator in the trigger issue; this is important, as it stops processing when caught up
      • Walk the issues immediately linked to the trigger issue, updating their dates, and setting the indicator when needed (i.e., has more links)
      • The scheduled trigger rule can process up to 100 at a time before it halts, and so set the schedule appropriately to allow the processing to finish before it starts the next batch
    • Disable the "Allow Rule Trigger" option in both rules

 

Kind regards,
Bill

Duc Thang TRAN
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.
January 24, 2025

Hello @Bill Sheboy 

Thank you for taking the time to share all the best practices and solutions.
For the first approach via webhook, I am a beginner with this method and am currently reviewing the documentation to understand it better. I hadn't thought of that. Thank you for the suggestion.

For the second approach, this is my backup solution, and it works perfectly.

However, the primary objective is to minimize the number of actions and reduce the time gap as much as possible, according to my PO. But if I can't find a better solution, I will keep this solution as my primary one.

 

Like Bill Sheboy likes this
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.
January 24, 2025

FYI...with the Scheduled Trigger approach, if you need the updates sooner you may open the rule in the editor and select to run it now rather than waiting for the next scheduled run.

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, ace, atlassian community event, donation, girls who code, women in tech, malala fund, plan international, kudos, community badge, badge, atlassian badge, International Women’s month, International Women’s Day, women's month, women's day

10 for Change at Atlassian Community Events

Show up and give back by attending an Atlassian Community Event: we’ll donate $10 for every event attendee in March!

Join an Atlassian Community Event!
AUG Leaders

Upcoming Jira Events