Forums

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

Jira Automation: Post a list of estimated child issues as a comment on the parent epic

Hamza Chundrigar
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.
October 25, 2022

Hi everyone,

I can't seem to figure out on how best to build the Jira Automation for my use case so I would really appreciate any guidance.

 

Use Case

  • Epic Alpha has five child story issues linked within it.
  • Each story has 3 fields that need to be populated in order to satisfy the condition. The fields are
    • Label = Backbone-Sync
    • Original Estimate > 0h
    • Custom Field (called 'Estimate Ready for Approval') = Yes
  • The automation should trigger upon a self-reflecting transition (when the status goes from Awaiting Estimate back into Awaiting Estimate)

Desired Outcome

Based on the info above, here are the steps in what I would like Jira Automation to do:

  1. End User transitions Epic Alpha from Awaiting Estimate back into Awaiting Estimate
  2. The system then looks for all child issues under the Epic that meet the following conditions:
    1. Child issue has the appropriate label
    2. Child issue has been estimated (Original Estimate field has an estimate greater than 0) — we are not using story points here.
    3. The radio button custom field Estimate Ready for Approval has the option Yes selected in the Child Issue
  3. The system then publishes the list of all of the child issues as a comment on the parent (Epic) issue

The comment would look something like this:

Please see below the list of issues (under Epic Alpha) that have been estimated and are ready for approval

  • Story 1 Issue Summary --> <Original Estimate Value>
  • Story 2 Issue Summary --> <Original Estimate Value>
  • Story 3 Issue Summary --> <Original Estimate Value>
  • Story 4 Issue Summary --> <Original Estimate Value>
  • Story 5 Issue Summary --> <Original Estimate Value>

The total estimate for all the estimated issues is = <Total Sum of all the Original Estimate Values for Stories 1-5>

 

Screenshot

Here's what I have built so far. I'm not sure if I'm going about this the right way, or if there's a better way to achieve what I'm looking for. I basically got stuck half way, so looking for guidance from this great community.

 

image.png  

 

Thank you!

3 answers

2 votes
James Navin
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 31, 2022

Hi @Hamza Chundrigar ,

The rule you've posted is actually branching into each child issue, which is good if you want to take action on those issues, but doesn't do what you need (which is to collate that information and take action on the parent epic).

The trick for this one is to use the "Lookup Issues" action to find the child issues that match your criteria, while still being in the context of the parent Epic.

Something like the following might be a good starting point:

Screen Shot 2022-11-01 at 9.39.23 am.png

For your case you would need to update the "Lookup Issues" action to specify all of the issue criteria you want to match on (e.g. labels, estimate existing etc.).

Hope that helps.

Cheers,

James

0 votes
Vishal Biyani
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.
October 27, 2022

@Hamza Chundrigar 

Rolling up non standard values from Standard issue to Epic level is not feasible.

Based on my research, rolling up story points at Story level to story points at epic level is possible using smart values. However, rolling up original estimates at Story level to Epic level is not feasible.

What i did was to use JIRA REST APIs, get the data points at Story level and then update the fields at Epic level.

I am using this as a batch process.

Your use case is bit more complicated. But from change log you can determine when From and To transition is same and then execute your remaining logic programmatically.

0 votes
Joseph Chung Yin
Community Champion
October 25, 2022

@Hamza Chundrigar -

Take a look on using smart value for issues to generate your desired custom comments add in your rule actions -

https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/

Hope this helps.

Best, Joseph Chung Yin

Jira/JSM Functional Lead, Global Infrastructure Applications Team

Viasat Inc.

Hamza Chundrigar
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.
October 25, 2022

Hi @Joseph Chung Yin 

it's not more so the format or structure of the custom comment I'm looking to get guidance on, but rather the missing chunks in my automation rule altogether that would allow me to satisfy the underlying use-case. (i.e. the steps leading up to the comment).

Though I appreciate your input. I've had that link bookmarked for some time now and it's definitely served as a valuable reference point :)

Cheers,

Hamza

Suggest an answer

Log in or Sign up to answer