Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Check for a Linked Issue in Another Project Within a "Single Project" Scoped Automation Rule

Haddon Fisher
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.
November 22, 2023

Question

Has anyone found a way, as part of an Automation rule scoped to a single project, to check for the existence of a linked issue in another project?

Context

One of my project admins has a rule which, when a specific component is set on an issue, clones the issue into a new project, and good design would have us check to make sure the cloned issue doesn't exist already.

swear in the past I've never had an issue doing this, but now I see all of the components explicitly stating the scope. I work really hard to keep global rules to a minimum because maintaining 1,600+ people's business logic with 1.5 admins is not feasible, so I really do not want to make this a global rule. 

It makes sense to me that single-project rules wouldn't be able to make changes to issues in other projects, but restricting searching seems like a pretty common use-case even within a single project.

3 answers

2 accepted

0 votes
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.
November 22, 2023

Hi @Haddon Fisher 

There are two-possible solutions for searching for issues in different projects from rules:

  1. make the rule scope multi-project or global
  2. use the Send Web Request action to call the REST API function to perform the issue search with JQL

That second one is not limited by the restriction of project-scope rules.  However with the changes to the packaging model / limits for automation rules, using Send Web Request will count as a rule execution for the limits.

Kind regards,
Bill

Haddon Fisher
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.
November 22, 2023

Thanks for this idea @Bill Sheboy...I haven't played with the "web request" action a ton, but it sounds like I have a reason to now!

Like Bill Sheboy likes this
0 votes
Answer accepted
Ste Wright
Community Champion
November 22, 2023

Hi @Haddon Fisher 

That's not a new parameter as far as I know - when using a single Project rule, it's limited to the scope of the rule.

To achieve what you're looking for, you'd need to use a multi-project/global rule.

Ste

Haddon Fisher
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.
November 22, 2023

I have some documentation that I originally wrote back in 2021 that makes me think this wasn't always the case on Cloud...the screenshot is cut off so I can't say for certain, but the logic wouldn't work as it's written today unless the rule was set as global and I am 99% sure it wasn't.

I also know this was a "bug" that was only recently fixed on Server\DC.

I'm sort of assuming you are right Stephen Wright _Elabor8_ though that the scope is impermeable. Just hoping someone sees something genius!

Ste Wright
Community Champion
November 22, 2023

Just for extra evidence, I found a post from 2020 from an Atlassian team member which confirms it is project-specific - see: https://community.atlassian.com/t5/Jira-Software-questions/Getting-a-JQL-from-another-project-in-automation/qaq-p/1459658#M95623

Ste

Haddon Fisher
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.
November 22, 2023

Wild! Have to look through this rule to see if I can figure out it's deal then. And maybe get my brain checked.

Like Ste Wright likes this
0 votes
Colin_Turner January 24, 2025

Maybe you could use a smartvalue comparison to see whether {{issuelinks.outwardIssue.project}} is equal to {{issue.project}}?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events