Forums

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

Automation - Create Recurring Epics

Tom Stevenson
Contributor
June 22, 2023

Hi all,

 

Does anyone know if you can create recurring Epics using Global automation that also consist of tasks? 

I can create the epic fine but how would I add the tasks inside of there?

2 answers

1 accepted

0 votes
Answer accepted
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 22, 2023

Hi Tom - Welcome to the Atlassian Community!

You would actually want to Clone the Epic and all of its children. The Marketplace app Deep Clone is probably the best thing to use. 

Tom Stevenson
Contributor
June 23, 2023

Thanks for the speedy reply John!

Are you saying there's no way to achieve this with just the built-in global automation section? I'm halfway there with the Epic being created I just need it to create some tasks for me inside of that Epic too.

FYI this is for recurring tasks such as sysadmin checks, I'd rather not have to clone anything and just schedule the Jiras to create themselves on a schedule.

Here's what I have so far:

image.png

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 23, 2023

Sure you can do that. I would add a custom field or some value to the Epic when you create it. 

Then I would create a second rule that when an Issue Created and Condition for issue type = Epic then add a new action for Create issue for each child issue to create. 

In the child creates be sure to include the Epic Link field and use this code:

{{triggerIssue.key}}

Like • Jean Ricardo Vitorio likes this
Tom Stevenson
Contributor
June 23, 2023

Sorry I'm new to Jira.

I've added a new label to the Epic which will hopefully qualify as the "custom field or value" you mentioned?

image.png

Does there need to be a second rule or can I just add the tasks as a component?

I am not following how to edit the Epic link field:


image.png

Like • John Funk likes this
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 23, 2023

Hey Tom - Sorry, I forgot that you are creating the Epic using the Scheduled Trigger. Yes, you can simply add a Branch as my buddy @Bill Sheboy  mentions above. 

The model I was using is when a Form is submitted in a JSM project and it creates the Epic automatically. Then I have various rules running that will create lots of child tickets based on values in the Epic. 

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 26, 2023

Click on add Component and select Branch

Then Basic branch

Then Most Recently Created Issue

Tom Stevenson
Contributor
June 26, 2023

Thanks John that sounds like it might be getting closer. It still seems to just create the Epic and no issues though - do you know where the problem is?

image.png

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 26, 2023

Can you post the Audit Log for the results after you run it? 

Tom Stevenson
Contributor
June 26, 2023

Here is the result, sounds like it's struggling to recognise the Epic creation?

image.png

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.
June 26, 2023

Tom, would you please post an image of the details section for your rule?  That may reveal a scoping issue which could cause this symptom.

If that does not help, it is possible the rule has become "glitched" due to several edit/publish cycles.  I do not know why that happens...just that it does.  The way to check for that is to disable this rule, and recreate it from scratch as a new rule.

Like • John Funk likes this
Tom Stevenson
Contributor
June 26, 2023 edited

Hi Bill,

Sure I appreciate the help!

FYI I have successfully created the Epic AND the Tasks however it does NOT link them together, they are all created separately. It seems like the "Most recently created issue" logic doesn't function how we want it - I guess the Epic we're making doesn't quality as an "Issue"?

image.png  image.png

image.png

Like • John Funk likes this
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.
June 26, 2023 edited

Sounds like some progress!

Now inside the branch when you create the tasks, what value are you putting/selecting for the Epic Link?  You can try typing in {{issue.key}} as that will refer to the branched-to issue: the epic just created.

Like • John Funk likes this
Tom Stevenson
Contributor
June 27, 2023 edited

Hi Bill,

I've tried most of the options in the branch behaviour but they either don't work with the previously posted error, or they just create the tasks and the epic separately and unlinked.

image.png

 

Like • John Funk likes this
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.
June 28, 2023

Your earlier rule seems like it should work, with branch to most recently created issue, followed by creating the tasks and linking to current issue.  (I think I gave bad information earlier on what to use, which I will correct in the earlier post.)  How about this one:

  • trigger: scheduled
  • action: create issue (for your epic)
  • branch: most recently created issue
    • action: create issue (for your task, and...)
      • For the Epic Link, type/copy in {{issue.key}}
      • This will appear below the field, and then you may select it for use
      • Inside of the branch, {{issue.key}} refers to the branch issue: your epic.
    • ...
Like • John Funk likes this
Tom Stevenson
Contributor
June 28, 2023

Hi Bill,

Thanks for your patience and support - we have success!

Like • 2 people like this
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 29, 2023

Great! Can you post the final solution so future readers can see the implementation? 

Tom Stevenson
Contributor
June 29, 2023

Sure! For the next poor soul who attempts this here is my final config. The key to the solution is the custom field inside the tasks linking it back to the Epic.

image.png

Like • 3 people like this
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 29, 2023

Thanks for sharing!

Like • Bill Sheboy likes this
0 votes
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.
June 23, 2023

Hi @Tom Stevenson 

I believe you can create the epic in the rule, and then either...

  • branch to most recently created issue, add the tasks in the branch and link to {{issue.key}} as that would be the epic, or...
  • create the epic in the rule, and save its key with {{createdIssue.key}} in a variable, and then reference that for the linking of the tasks

Kind regards,
Bill

Tom Stevenson
Contributor
June 26, 2023

Hi BIll,

For option 1 I don't see how to branch to the most recently created issue?

image.png

Like • John Funk likes this
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.
June 26, 2023

Tom, it looks like you figured out the branch in the thread started by John.  Let's stick with that one to try to diagnose this.  Thanks!

Like • John Funk likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
atlassian, loom, AI, meeting recording, community

[NEW] Record your meetings with Loom

Welcome to great meetings, with less work. Automatically record, summarize, and share instant recaps of your meetings with Loom AI.

Learn more
AUG Leaders

Atlassian Community Events