Forums

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

Transition an issue based on an issue key using Jira automation

Sidharth verma August 22, 2024

I want to transition a specific issue which i have found using the search in a particular status. but when i use the transition and issue automation it gives me an option to only move the issue which has triggered the automation. How can i move a specific issue based on issue key or any other value of the issue ?

3 answers

1 vote
Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 23, 2024

Hello @Sidharth verma 

I had a typo in my previous reply, which I have now edited. I meant to say you can't have one branch dependent on the actions of another branch.

Before I can provide any additional advice I need to understand what you are trying to accomplish with your rule. In order to achieve that understanding I need more information from you:

1. Please provide images that show the entire automation rule.

2. Please explain in words what you want to accomplish.

I don't understand what you are trying to accomplish with this branch.

Screenshot 2024-08-23 at 9.27.25 AM.png

When you use a branch that typically means you want to take some actions for each of the issues identified in the branch command (the JQL you specified.

So, for each issue you find in the JQL you are then executing a Lookup Issues action that does not appear to be tied in any way to the information in the issues selected by the branch JQL.

And then you are creating at least one variable, and conditionally a second variable. What are the details of the statements you are using to set those variable values?

Then you are trying to run another branch based on a smart value. What are the details of that branch action?

Sidharth verma August 23, 2024

Hi @Trudy Claspill

 

my main objective is hereunder:

I want to autoassign the issues based on the trigger when the assignee sends the issue to QA stage. the autoassignment should be done based on the below criteria:

 

1.) first check who all are the free team members. i.e. who are not assigned with any issues.

2.) based on whoever is free we need to first identify by scanning all the unassigned issues that a similar issue has been done by the free team member or not.

3.) If a similar issue has been done by the free team member, then transition the issue to the next stage and assign the issue to the free team member.

I am currently using assets to store the information about assignments so that i can easily query it based on other criteria's. below is the snapshot of my rule:

 

Screenshot 2024-08-23 225043.png

Screenshot 2024-08-23 225151.png

Screenshot 2024-08-23 225242.png

The rule is not fully completed yet and there might be some mistakes in it but in a nutshell i want to transition a specific issue based on the critirea i have mentioned above. do let me know if you have any more questions and i would be happy to answer.

1 vote
Rebekka Heilmann _viadee_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 22, 2024

Hi @Sidharth verma 

what does your rule look like so far? Where did you search/find the issue?

Generally speaking, you'd need to branch the rule over whatever issues you want to edit. Any action in the branch will be on the "Current issue" rather than the "Trigger issue" per default.

Could you post a screenshot of your rule?

Sidharth verma August 22, 2024 edited

Hi @Rebekka Heilmann _viadee_,

below is the screenshot of the rule on how it looks like:

1.) branch 1 - i am trying to search for the issue key using various conditions using a JQL search. once i have found the issue key i put it in a variable called similarapp.

2.) Branch2 - I want to transition the issue that i have found in branch 1 only and no other issue. However, I am not sure if its going to work or not ?

Is there anyway i can find a solution to the above problem?

Screenshot 2024-08-23 100929.png

 

 

Rebekka Heilmann _viadee_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 22, 2024

The problem I see is that Branches don't wait for other branches to finish. So I assume there are no smart values to branch over at execution time. 

You can check that by logging the Smart value with "Log action". Sometimes a "refetch issue" helps.

Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 22, 2024 edited

EDITED: Correction where I said "can" and meant to say "can't"

 

Hello @Sidharth verma 

There are a few problems with the structure of your rule.

1. Branches run in parallel. You can CAN'T have one branch dependent on information from another branch. Refer to: https://confluence.atlassian.com/jirakb/in-the-automation-parallel-execution-of-the-branches-to-main-thread-can-produce-incorrect-unexpected-outcome-1115147731.html

2. Variables you create in a branch do not exist outside of that branch. You can create a variable inside a branch and then use that variable anywhere outside of that branch.

3. Can you clarify your intention where you are using a JQL based branch to select issues and then using a Lookup Issues action after that? The Lookup Issues action does not appear to have any criteria related to the branch you have started based on the JQL. By branching on a JQL you are telling the rule that there are actions you want to take for each issue found by that JQL. How does your Lookup Issues action factor into that? 

Also, please share the details of the variables you are creating. That might help us understand your intent.

Like • Joseph Chung Yin likes this
Sidharth verma August 23, 2024

Hi @Trudy Claspill ,

 

My intention is to find an issue in particular status using a JQL search and then transition that particular issue only to the next stage. 

I am currently trying to add that into a variable and use the variable in the branch. from your comments now i understand that variable will not be available in the next branch which is fine. but if i were to populate the variable outside the branch and then run a separate branch using the smart value will be i able to transition that issue ?

Rebekka Heilmann _viadee_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 23, 2024

So you only ever expect to find one specific issue with a set jql?

Sidharth verma August 23, 2024

Hi @Rebekka Heilmann _viadee_ ,

 

Yes...... but even if i get multiple issues.....can they be transitioned using the rule above ?

Rebekka Heilmann _viadee_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 23, 2024

If you can, you should change the second branch to "JQL" and put in the query so you can branch over the jql results. 

But from looking at the complexity of the first branch I'm not sure whether a single jql is sufficient..

Sidharth verma August 23, 2024

Hi @Rebekka Heilmann _viadee_

No, a single JQL will not be sufficient. can't we branch it based on smartvalues and take the variable value as input to the transition action ?

0 votes
Joseph Chung Yin
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 23, 2024

@Sidharth verma -

I agreed with what both ( @Trudy Claspill and @Rebekka Heilmann _viadee_ ) leaders comments.  Can you also provide what is your triggering event for the automation rule?

Please advise and looking forward in supporting you.

Best, Joseph Chung Yin

Sidharth verma August 23, 2024

My triggering event is when the packaging engineer moves an issue from packager inbox to QA or Packaging to manager status. 

see below:

Screenshot 2024-08-23 232515.png

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
atlassian, atlassian community, journeys for jira service management, journeys for jsm, eap jsm atlassian, early access program atlassian, early access program journeys atlassian, early access program journeys jira service management, join atlassian eap

Join the Early Access Program (EAP) - Journeys for Jira Service Management 🚪

Journeys is a brand new feature in Jira Service Management that helps you streamline various processes in your organization that may cross multiple departments, such as employee onboarding or off-boarding that require action from different teams. ✨

Join the EAP →
AUG Leaders

Atlassian Community Events