How to use conditional logic to perform different actions on result of lookupIssues

vruttant.mankad
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 5, 2024

Hi,
I have the below rule currently setup which runs every Thursday and Monday . 
It looks up issues based on a condition and sends out an email to the assignees.


My problem is that if I remove the Summary ~ "mainstream" filter , I get an error in advanced branching saying that payload of custom variable is too large. 

What I want to achieve is , 
1) Lookup issues without the "Summary" filter
2) Seggregate issues into 2 different branches based on the Summary filter post that and send out emails to the assignees so I can avoid the payload too large error. 

Not able to figure out how do I apply a IF-ELSE condition here and have seperate branching looping over each issue.

I dont want to create 2 different rules for this as there can be multiple different values for the Summary field and this would mean I would need to create 1 rule each for each Summary type.

Thanks

Screenshot 2024-05-06 at 11.46.50 AM.png

1 answer

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.
May 6, 2024

Hi @vruttant.mankad -- Welcome to the Atlassian Community!

Please post an image of the audit log details showing that error message.  That will help provide context for this symptom.

Until we see that...

First thing, please describe the problem you are trying to solve with this rule.  That is, "why do this"?  Knowing that may help the community to offer other suggestions.  Thanks!

 

I hypothesize the error you see indicates there are more than 100 issues returned by that JQL statement.  And, you are trying to solve that problem by adding filtering on the Summary, which appears to contain some additional data, such as the keyword "mainstream".

 

The normal pattern for a rule like this to send a single email to each assignee is:

  • trigger: some trigger
  • action: lookup issues, to get all the issues
  • smart value condition: check if there were any results in the lookup, comparing {{lookupIssues.size|0}} is greater than 0
  • branch: on the distinct Assignee with {{lookupIssues.assignee.distinct}}
    • action: lookup issues, to only the ones assigned to the branched-to assignee
    • action: send your email

There is no nested branching, such as to branch on the Summary indicator and then branch on the Assignee.

 

Let's assume you have less than 100 possible Assignee values.  Some possible workarounds to split up the data for your scenario are:

  1. Review your JQL to determine if there is a sort order (i.e., ORDER BY clause) that will ensure each distinct Assignee is represented in the first 100 issues.  Then no other rule changes are needed...unless a single person has more than 100 issues.
  2. Rather than storing that indicator in the Summary field, explicitly store the value in a field, such as a Label, Component, or custom field.  Then use separate Lookup Issues and branches for each value.
  3. Use separate rules, with separate JQL, for each possible Summary indicator value for which you wish to send email notifications.

 

Kind regards,
Bill

vruttant.mankad
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 6, 2024

Hi @Bill Sheboy ,

Here is the screenshot of the error in audit logs. I just have about 18 issues that are fetched using the JQL so 100 issues limit is not the issue. 

The problem I'm trying to solve here is sending an email as reminder to the assignees of the issues if their issue is still not in DONE state.

Here, just 18 issues in 1 query is giving this error and hence I want to split the processing based on the summary filter if possible. So, have a branch that processes the different summary filters separately as to not get this error. Let me know if there is any other workaround also for this.

Please let me know if more information is required. 

Thanks,
Vruttant Mankad
Screenshot 2024-05-07 at 12.05.15 PM.png

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.
May 7, 2024

Please show an image of your Advanced Branch details.

If you are trying to send one email for each assignee, please see the suggested solution I described earlier.

As your rule is written, it appears you are trying to send email for each issue.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events