Hello,
I'm hoping we're just over thinking this, and there's an easy answer, but we currently have 60+ JIRA stories in a Kanban project created by the Scheduler on the first of each month. What we're trying to do is migrate those stories to the Scheduler in a JIRA Work Management board and automatically link them through an Automation since the tickets have dependencies on each other (can be one to one, or one to many dependencies). This way the progression will show up in the Timeline tab of JIRA Work Management. Below are examples of the ticket structure:
- Ticket A is dependent on B being completed and A should be blocked by B
- Ticket D is dependent on B and C being completed and D should be blocked by B and C
The goal is to try to avoid someone needing to manually go in and link the tickets in the JIRA Work Management board.
Regardless of the way the issues are created, an automation rule would need guidance for the linking.
If you are creating these with a scheduled trigger automation rule, the linking could probably occur there, either through absolute (e.g., a specific key and link type) or relative linking (e.g., link to the last issue created in the rule).
Kind regards,
Bill
@Bill Sheboy I was working to help @Dan Schetley with this and I was getting stuck on the relative linking related to the "last issue created". It kept trying to reference itself. For example:
Automation Creates Issue1 then Issue2. When I use the relative linking, it sees Issue2 as the "Last Issue Created" and errors out as it cannot reference itself. any thoughts for getting around that?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Joe Tobey
There are a couple of solutions for that...
First, as issues are created in the main execution path of the rule, two smart values are available: {{createdIssue}} and {{createdIssues}} (note the plural). With the second one any of the previously created issues could be referenced using the get() function in the list, with {{createdIssues.get(n)}} where n is a 0-based index for the issues. And so the first one is 0, and the key is {{createdIssues.get(0).key}}
That method breaks down if the issues are created either inside of an if/else structure or a branch, due to scoping issues. (There is sometimes a work-around for that, using the method below.)
The second method is to save the {{createdIssue.key}} with the Create Variable action after the issue is created. This method is often used when cloning a tree of issues, like the epic and its children.
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Bill Sheboy ,
Thanks for the quick responses. Would it be possible to send an example automation for my example above:
Ticket D is dependent on B and C being completed and D should be blocked by B and C
I think if we could get that then we can build upon it from there.
Thanks,
Dan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The only tricky part about a rule like this is setting the issue links: when you type in the smart value, it appears below the field, and then it can be selected for use to link the issues.
Here's an example rule. The links must be added one at a time, due to limitations in the rule actions (and supporting REST API functions).
Please try that first to confirm it works as you expect, and then expand for the remainder of your scenario.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am glad to learn that helped. Please consider marking this question as "answered", as that will help others in the community with similar needs find solutions faster. Thanks!
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.