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

Automation rule on status change of jira ticket.

Neeta Dubey
Contributor
April 4, 2024

Hi All,

I need help in creating a jira automation.

Scenartrio:

I've a ticket in Project A and clone of that ticket in Project B.

Once the status change of that specific issue type ticket it should change status of that cloned ticket in project B. Is it possible to achive?

3 answers

1 accepted

0 votes
Answer accepted
Marco Brundel
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.
April 4, 2024

Hi @Neeta Dubey ,


In an automation rule you can specify Issue transitioned as the trigger. And in a rule you can include a Branch where you then define an action in the branch for, for example, the linked issues.

Can you continue with this information?

regards, Marco

Screenshot 2024-04-04 at 14.16.25.png

1 vote
Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 4, 2024

Hi @Neeta Dubey ,

You need to create 2 automation for creation of clone ticket to and updating status.

 

Automation 1:
When: Issue created

Condition: Issue fields condition - Project - Project A

Then: Clone issue - Project - Project B (You can add more fields changes if you want)

Automation 2:

When: Issue transitioned - leave it blank status from and to so all every changes in status will trigger the automation

Condition: Issue fields condition - Project - Project A

Branch rule / related issues: Branch rule / related issues - "Type of related issues = Linked Issues" and "Link Type = is cloned by"

Then add Action in the branch - Transition issue - Destination status - Copy from trigger issue.

 

NOTE:

Both project should have same workflow.

Dont remove/update the linked issue because this is the way to track the clone issue.

The scope of both automation should be Project A and Project B (you can see this under Rule details)

Hope it helps!

Neeta Dubey
Contributor
April 5, 2024

Hi Dexter,

thank you so much for info  it works well when cloned issue is in the same project although I've included both the projects in scope.

it faild when I did below - 

I created defect in Project A, cloned it, moved the clone to Project B, change the status of the mqms defect in Project A, and the status of the Project B defect didn't change

Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 5, 2024

Hi @Neeta Dubey ,

Do you create the 2 automation? First automation will directly create clone issue in Project B. No need to manually clone then move to project B. And the second automation is the one will update the issue clone base on the transition made in project B.

Maybe you can show us the 2 automation you made so we can check it.

Neeta Dubey
Contributor
April 5, 2024

Thanks Dexter, When I move ticket from Inprogress to Implemented, I've a transition screen and some validators, which is same in both the tickets, would that we causing the issue.

 

Also, I didnt automate it because I don't need to clone issue every time, is manual cloing is a problemsnip 3.png.

 

Also, i modifed the condition to "Clones" as I would be making changes in the cloned issue.

This works well when I dont have any transition screen like moving between to do to backlog.

Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 5, 2024

Can you screenshot the auditlog in automation. And let see what happen in automation process.

Neeta Dubey
Contributor
April 5, 2024

They share the same WF and transition screen, although the values are not getting copied in the destination project. If there is no validation then rule works well.

error.png

Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 5, 2024

Error is because of the Fix version and Risk are required. So you may create new workflow without that validation for your Project B (if this is not required in your project B). You can just copy the workflow scheme and workflow of Project A. then update the new copied workflow, remove the validation then update your copied workflow scheme, align the new workflow in scheme then use the copied scheme in your project B. So the result will be Project A is the only one that have validation.

Neeta Dubey
Contributor
April 5, 2024

Thanks for your quick reply Dexter. I really appericiate it however if I remove validation for project B then it may leave to inconsistency in ticket data.

In project A ticket, All fields will have relevant information.

In project B ticket, those fields on which validation worked in Project A would be empty in project B.

Let me know if it not work in the above way.

Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 5, 2024

If that so, you need to copy too the required field value to your copied ticket. So it will not be empty. It got an error because the field is empty on your project B ticket.

Neeta Dubey
Contributor
April 7, 2024

Hi Dexter,

Thanks for your prompt response,

but all different transition have different validators, Could I put all validators at once,

also, how I could I copy mandatory fields from project A ticket to project B?

Dexter de Vera
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 7, 2024

This will be complicated because you want to sync everything. Every changes in field , status etc. And it will affect the performance due to plenty of automations running every changes. Maybe you need to adjust it. Let your team just access the linked issue (clone) to see details about everything. Or just work in 1 project if every proccess should be the same. Also if you are willing to add plugin. There are plenty of syncing ticket app that you can use to sync issues like exalate-jira-issue-sync-automation etc.

Hope it helps.

0 votes
Dhiren Notani_Exalate_
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.
April 24, 2024

Hi @Neeta Dubey ,

Thanks for posting your question here on the community.

I am Dhiren, one of the Solutions Engineers working at Exalate.

Although it might be possible to do this via Jira Automations, but the more robust and flexible way to achieve this is using a dedicated and fully decentralized integration solution like Exalate.

Exalate uses Groovy based scripting engine which offers you limitless customizations, and not only you can sync issues seamlessly, but with that you can choose what fields to map (even custom fields of any type can be synchronized).

Thanks, Dhiren

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events