Is this automation possible?
Asked by Dawn E Chaplin:

Hi. I was wondering if this logic would work in JIRA.

1. Everytime we create a Story, with specific words in it (e.g. ABC123) with a specific Component there is automation to add a specific list of SubIssues/SubTasks (based on the Component). (I'm sure this first step can be done.)
2. Duplicate this Story and this set of Component and set of SubIssues/SubTasks under a set group of Epics . So we'd have Story ABC123 with Component and set Subtasks, duplicated against multiple Epics. (This is the part I'm unsure of.) I know you can't have a single story with multiple Epics so I'm trying to figure out how to not manually have to create an the same Story/Component/SubIssues/Tasks across multiple Epics.

Thank you.


Answers:
author: Camilo Galleguillos
body: Hi, [@Dawn E Chaplin](/t5/user/viewprofilepage/user-id/5471848)

You can use the [Clone Plus for Jira](https://marketplace.atlassian.com/apps/44043/clone-plus-for-jira?tab=overview&hosting=cloud) plugin to clone the full story with its children, and [JSU Automation Suite](https://marketplace.atlassian.com/apps/5048/jsu-automation-suite-for-jira-workflows?hosting=cloud&tab=overview) would help you automate the actions.

However, I would not advise to automatically create and clone issues, as it commonly leads to clutter and tons of unused issues and subtasks. My recommendation is to evaluate the goal you're trying to achieve with this and try to find another solution. If what you need is to have multiple teams working in parallel on the same features, a combination of tasks, subtasks, and linked issues with components could help organize and tie everything up.

Best,  
**Camilo Galleguillos R.**

comments: author: Dawn E Chaplin
body: It will be mandatory for us to close out each SubIssue/Task weekly as well as the Story. Unfortunately, it's mandatory and I'm trying to find ways to automate some of the work vs. doing everything manually. I guessing we can set up an trigger for auto closing them, but we're not ready to get there as we have to make sure all the users are entering their info. correctly and timely first.


author: Dawn E Chaplin
body: And thank you VERY much for your time and expertise.


author: Dick
body: Hi Dawn,

It is possible to make an automation with a manual trigger that:

1. Checks if the (trigger)issue you invoke the automation from is of issue type Epic.
2. if true, generates your story and subtasks, if not you end the automation.

It depends on the amount of epics in your project if you would like to do this manually for each epic or want to do it batch-style using the project name of the triggerissue to find a list of epics that would be processed according to your needs.


author: Pablo Vergara
body: Hi [@Dawn E Chaplin](/t5/user/viewprofilepage/user-id/5471848)

I think I can help you with this first part, but as you know, the "daemon is in the details," so let's be as specific as possible.

If you help me clarify the first requirement below, I can surely support you ;)

1. Everytime we create a Story, with specific words in it (***in the summary? within the description? as part of the text body in any of the existing comments?*** ) (e.g. ABC123) with a specific Component there is automation to add (***"add" meaning to ++link++ those issues? to "add" them as a "list" in a comment added to the issue? to "add" them as part of a custom field value?***) a specific list of SubIssues/SubTasks (based on the Component). (I'm sure this first step can be done.)

- Pablo

comments: author: Dawn E Chaplin
body: Thank you so much.

So #2 is not possible?

As for above, here is more detail as an easy example:

Trigger - Create a Story with he word "Timesheet" in the Summary and ine Component field when creating it we chose Component A. System will then add a set list of SubIssues/Tasks (that we would provide the 1) text for each Subissue/task Summary, 2) tell it to use take the reporter of the Story and duplicate that for each Subissue/task and as well as that name in the Assignee field for each.

Hope this helps.


author: Pablo Vergara
body: The explanation is helpful, and the configuration should be straightforward for #1.

You can review the configuration and a quick test I've recorded using an Automation for Jira rule. This is for DC/Server but should be pretty much the same if you're on Jira Cloud.

<https://drive.google.com/file/d/1vhDW9SNRKc5OUQeJjRue1MiWKzG5Dglz/view?usp=sharing>

(There could be slight variations you can make on the rule, but the main idea is there)

I hope it helps you!

*- Pablo*


author: Pablo Vergara
body: Regarding #2, I don't see it possible to perform solely using the Jira built-in automation features. A feature request to Atlassian asks for a better cloning mechanism when dealing with Epic issue types. (<https://jira.atlassian.com/browse/JSWSERVER-7721>)

I see that Jira (DC/Server) and Automation for Jira don't offer an option to set the Epic Link field using a calculated value (smart value). That's unfortunate and should be improved.

As [@Camilo Galleguillos](/t5/user/viewprofilepage/user-id/4777596) indicated, I would explore marketplace apps to extend automation functionality. JSU / Clone Plus for Jira seems to be a great option there.

*- Pablo*


Tags: jira-unknown-hosting-type

unknown-hosting-type