Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,359,846
Community Members
 
Community Events
168
Community Groups

Chaining multiple rules does not work

Hello there,

 

I am struggling understanding how to chain multiple automation rules.

Here my use case :

RULE 1 :

Capture d’écran 2022-08-26 160324.png

  • When an Epic is created, the rule 1 will create a serie of tasks with the EPIC as parent

SUBSENQUENT RULES :

  • I have a set of subsequent rules that assigns tickets, copying the component from the EPIC to the tasks and other things like that.
    Capture d’écran 2022-08-26 160532.png
  • All the subsequent rules have the "Allow rule trigger" checked
    Capture d’écran 2022-08-26 160515.png

First, you may asked : why subsequent rules and not having those in the 1st rule? That's because the fields on which these rules are based are not mandatory. Plus, it was way more flexible in case the value of on the fields that triggers changes afterwards.

The thing is : it doesn't work.

  • If the fields are updated after the epic creation, everything works fine!
  • If all the fields necessary for the subsequent rules are added as epic creation, the subsequent rules triggers alright but shows : "Branch rule / related issues, No related issues could be found.". So it seems that Rule 1 is indeed trigerring subsequent rules but to early in the process and the tasks haven't been created at that time.

 

Please HELP :) 

2 answers

0 votes

Hi @Antoine Claudé-Pénégry -- Welcome to the Atlassian Community!

If you want two rules to execute one after the other (i.e. you intend the first rule to complete before the second rule starts) try structuring the triggers to do that.

Your second rule is triggered on change to the Epic's assignee, which could certainly occur before the first rule completes.  In fact, the opposite could occur too, based on when the rules start!

I suggest pausing to:

  1. map out what problem you are trying to solve,
  2. decide the order of steps in your solution, and then
  3. build rules which will occur in that order.

One way to do step #3 is to identify the unique condition which confirms the order, such as adding a comment as a final step in the rule.  And, pay close attention if your rules contain any branches:

  • branches which can process one-and-only-one issue (e.g. on parent, last created issue, current issue, etc.) get run in-line
  • however branches which could process more than one issue (e.g. issues in Epic, JQL, etc.) run in parallel and asynchronously.  There is no guarantee they will finish before the next rule step, or even all the other rule steps.

Kind regards,
Bill

Thanks Bill. That's what I'll do.

Go back to process mapping and rethink the rules based on the expected outcomes!

Like Bill Sheboy likes this
0 votes
Alexis Robert Community Leader Aug 26, 2022

Hi @Antoine Claudé-Pénégry ,

 

the issue might be because the first rule is executed in the background and does not finish before the next one starts. Have you tried adding the action "Re-fetch issue data" before the branch ? 

 

Let me know if this helps, 

 

--Alexis

It is probably that.

"Re-fetch issue data" is which rule? The first one and the subsequent ones?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
Community showcase
Published in Jira Software

An update on Jira Software customer feedback – June 2022

Hello Atlassian Community! Feedback from customers like you has helped us shape and improve Jira Software. As Head of Product, Jira Software, I wanted to take this opportunity to share an update on...

4,963 views 18 31
Read article

Atlassian Community Events