How to get notifications when all sub-tasks are complete?

Justin Cox July 31, 2013

I may be a bit out there but in our organization, it's very common for there to be an "owner" (assignee/reporter/watcher...doesn't matter) of a parent task or user story. I'm finding it very difficult to know when all sub-tasks have been completed, so that I can take the appropriate action on the parent.

We have a workflow setup where sub-tasks of a parent go from To Do > In Progress > Done (closed). But the parent task (lets assume it's a user story) goes from To Do > In Progress > Ready for QA > In QA > Done (closed).

As you can see, there are additional steps that need to occur for the parent task. The auto-transition doesn't work for us, as it puts the parent straight to close, so we have instructed our users not to use that (wish I could turn that off).

How, as an "owner" of the parent task, can I be notified when all of the sub-tasks are completed? Right now, I have to manually check each parent every day (sometimes multiple times a day).

2 answers

1 accepted

0 votes
Answer accepted
Udo Brand
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.
August 15, 2013

Hi Justin,

as Bhushan noted you can use script runner plugin. Use following filter:

issuefunction in hassubtasks() and status !=closed and not issuefunction in parentsof("issuetype =sub-task and status != closed")

Then you can subscribe that Filter.

Udo Brand
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.
August 15, 2013

if you want the subscription on an hourly basis add

... and issuefunction in parentsof("status changed to closed after -1h")

Justin Cox August 16, 2013

Ok, thanks for the information. I'll give that a try. Still working on getting script runner approved by IT :)

1 vote
Bhushan Nagaraj
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.
July 31, 2013

Hi Justin,

There are quite a few ways to do this. You can write a post-function for the sub-task close action to send a notification only if all sub-tasks are closed.

You can also write a listener. I have a tutorial available here for that https://bitbucket.org/bhushan154/jira-listener-tutorial/wiki/Home

Also check out the script runner plugin which can do a lot for you

https://marketplace.atlassian.com/plugins/com.onresolve.jira.groovy.groovyrunner

Cheers

Bhushan

Justin Cox August 1, 2013

Hi Bhushan,

Thanks for the info. I'll definately keep looking at script runner, seems useful. The listener tutorial is probably a bit outside my skillset but I would like to ask if you can further elaborate on your first point;

You can write a post-function for the sub-task close action to send a notification only if all sub-tasks are closed.

Not sure I totally follow what you are saying there. Post function on a sub-task close but looks at other sub-tasks?

Bhushan Nagaraj
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.
August 1, 2013

Hey Justin,

Even this requires you to write some code. Send me your email id and I will be able to help you out with a plugin if I find some time this weekend.

Cheers

Bhushan

Justin Cox August 15, 2013

Thanks for the offer Bhushan but to be honest, I would be more interested in an enhacement request that I could vote for. Not to down-play your willingness to help, I appreciate that but I really don't want to get into customizing at that level, nor do I have the technical skill to do it ;)

Suggest an answer

Log in or Sign up to answer