You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.
Join groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
Hello,
I have a working part of a rule where:
1. an issue is created
2. the branch "For the most recent created issue" creates another issue and links it to the one above.
I need to link an issue created in this branch to another issue too.
I tried the same approach when another issue is followed by the branch "For the most recent created issue" but didn't find a way to pass there issue key of an issue created before.
Using JQL looking for an issue with some custom field value doesn't pass it.
Appreciate any idea.
BR,
Ivan
@Ivan Donigevich,
I'm not quite following exactly what you are trying to do, but I'd take a look at using the Create variable action.
You can use this to store a value which you can access later. So after creating an issue, perform the action
You can then later access this variable using {{recentissuekey}}.
Yes, and... to the suggestion from @Kian Stack Mumo Systems
Create Variable has some limits for scoping, so if you create a variable inside of the branch it may not have a value elsewhere in the rule. As a work-around you may want to create the variable and assign it to {{createdIssue.key}} before you branch.
Please see this article for some "spirited conversation" on this topic:
Best regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Kian, Bill,
Thank you for the prompt response.
I guess using the variable value should be for the 2nd linked issue via Editing Issue action in its Additional fields section where I can assign an issue key and a link type to sub fields of Linked Issue field in JSON.
Can you please suggest how these sub fields are named and the assignment would look like? Here I haven't found them.
BR,
Ivan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Ivan Donigevich,
I'm not quite sure that I'm understanding what you are asking. Perhaps a screenshot of the rule would be helpful.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ivan, would you please post an image of your rule? That may provide some context for the community to help you on this next question? Thanks!
__Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Bill,
The actions are that.
The long arrow shows extension of the rule, the blue one - what issues are to be linked, the short arrow - where I'm going to edit the most recent issue and what issue key with.
So here:
1. Story and 2 Tasks are created, then the Tasks are linked to the Story (the left part of rule)
2. The right part: Task is created and it is to be linked to the 2nd Task.
BR,
Ivan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for that image of the rule.
Just to check, is this working as you expect? Branches run asychronously and so do not necessarily complete before the following steps, leading to timing issues in rule execution. The 3rd task you are creating is *outside* of the branch, and so it is unclear what the value of "most recently created issue" will be:
If all of the creates are within the branch (or outside of a branch) you can probably expect the steps occurring sequentially.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, it's working correctly, the issues are created and linked in the order they are in the main rule and its branches. I believe as the branches are on different levels of the main rule trunk, a fork point stops going down the trunk till a branch is finished. Eventually it just expected to be so!)
Unfortunately branches cannot be nested else I would resolve this case easily. So now I need to know how to put a value in sub fields of linkedIssue field. Probably it can be done in Additional fields section of the Edit Issue fields action.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ivan, I am glad to hear it appears to be working, and...
Just to confirm what I was describing: the way the rule appears in the editor does not guarantee execution order when there are branches. Once you reach the point of a branch, anything inside of the branch gets queued to execute independently. The documentation states that branches with only one issue stay in-line (sequential), however some recent posts in the community indicate this is not the case. So, buyer beware for timing issues. ;^)
Best regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Bill,
Thank you for the support.
Even if branches work simultaneously I believe each works on the most recently created issue related exactly to it and not on some created later for another branch or so.
Anyway I would test passing createdIssue.key to another issue's linked issue field as I can't see another way to link 2 issues created in different parts of a rule.
So the current question is how to assign values to the Linked Issue sub fields in JSON.
BR,
Ivan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Bill,
I'm going to get an issue key of one of tickets to be linked in some variable as it's suggested by Kian and to assign it to the Issue sub field of another ticket's Links field. Also I want to assign a link type to the Linked Issues sub field.
So I expect to get in JSON section of Edit Issue action something like that:
"fields": {
"Links": {
"Issue": <Variable with {{createdIssue.key}}>
"Linked Issues": "blocks"
}
}
But I don't know how the Links field and its sub fields can be applied - here they aren't available in the list. Does it mean - no way?
BR,
Ivan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To add links with types using JSON, please look at his documentation:
https://support.atlassian.com/jira-software-cloud/docs/advanced-field-editing-json/
But if you are instead trying to "walk the tree" downward, updating issues in linked issues from the JSON, I do not believe that can work. A specific issue must in scope (e.g. within a branch, or triggerIssue) for the JSON to work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Bill,
Thanks a lot for the link - it's what I've been looking for.
I will play with Linking issues JSON - hope it will help. Anyway I don't see another way to pass parameters of one issue to another.
BR,
Ivan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Community members! We have an upcoming research study for Confluence and we’d like to invite you to provide advice and answer questions. We’re developing a new experience for Inline Comment...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.