It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Recurring Tasks in JIRA

I'm sure there are several ways of doing this, however since I recently crossed on questions regarding this topic, I figured I might as well share it in details :).

What's the problem?

For starters, I work in a bank, IT Division, Software Development Department. Also I'm the guy in charge for JIRA and Confluence dev & app administration.

In our department, being developers, we don't have that many recurring tasks. Sure there are recurring actions, meetings, but tasks... no. On the other hand colleagues from the IT Operations department tell a different story. They have daily maintenance checks and procedures to execute. This was becoming an overhead, as they still needed to keep a manual "checklist" for the order of tasks and also open a new JIRA issue each day (we don't keep issues open to log on repetitively).

 

So... Solution anyone?

We needed something automated, but also configurable. Meaning that this should not be a hard-coded template which would require tinkering to change.

This was one of the cases where I didn't do much research ahead.

Not necessarily a bad thing, since the solution seemed pretty obvious based on our current setup.

We clone issues a lot in our JIRA and have this "automated" in the workflow, which saves a bit of time. So essentially cloning a "template" would work for this one.

 

Here's the high level plan we came up with:

  • Create a "Template" project created with basic 2 step workflow (active / inactive)
  • Project Must have Task Issue Type only as available (optional sub-tasks)
  • Same screen configuration as "Target" project
  • Each task in the "Template" project will serve as an issue template
  • Workflow must have a self pointing "cloning" transition into active status, which will have a post function to clone itself into the "Target" project
  • Script Listener will run each day at 7AM, filtered by JQL (project="Template Project" and status=Active) and will execute the "cloning" transition (if different frequencies are needed a parameter (example: label="weekly") must be used and listener configured with custom script, or just different listeners by itself for each frequency)

Benefits of this approach are that templates will always be available to reconfigure easily, disable/enable in case of need and they will not be hard coded, which would always require a developer available to change the template.

Requirements:

  1. Adaptavist ScriptRunner for JIRA
  2. Checklist for JIRA
  3. One member per Unit will need to be in charge and properly create/maintain templates. (Specify correct labels and other fields, such as Business Service in our case)

We already had these add-ons in place, so that's the reason why I leveraged on them.

 

Details

1.Create a Template project

Project Details

image.png

Workflow

image.png

Upon creation, each issue will be automatically marked with a label, "recurring-task". This will help to easily identify these kind of issues.

 

Create Screen

is the same as Target Project Task Screen. This will make sure that the fields are always consistent.

image.png

Checklist can either be left empty and configured later, or configured directly from the Create Screen.

User can enter all the tasks for that issue. Checklist items can be Mandatory or not (mandatory blocks resolving unless checked).

image.png

 

2.Script Listener

Using Built In Groovy Scripts from Adaptavist Script Runner, an Escalation Service was created, which triggers the "Recurr"  transition for the selected issues.

This transition will clone the issues in Target project.

image.png

 

Issues are filtered using JQL:

project ="Recurring Tasks" and issuetype =Task and status =Open

 

Additional actions required are setting the reporter as our "Robot" use instead of original issue reporter and set the issue as Unassigned:

import com.atlassian.jira.component.ComponentAccessor
def newReporter = ComponentAccessor.getUserManager().getUserByKey('robotUsernameGoesHere') 

issue.assignee
=
null
issue.reporter = newReporter

 

3.Identifying Recurring Tasks

Since all issues have a predefined label, they can be easily filtered.

In our main "Target Board" a quick filter will be added, "Recurring Tasks". If used in combination with "My Business Services" it will produce the output of "My Recurring Tasks" (optional quick filter).

My Business Services - this is something we use to differentiate between the applications each user is responsible for. We used Insight to do this and it allows all of us to have a single view. Will talk more in depth about this in another article and link it here.

 

image.png

 

Also users can create their own boards if they choose to do so as normally. JQL can be used for simple board:

project ="Target Project" and issuetype =Task and labels =recurring-task

 

Or they can customize it only to their Business Services:

project ="Target Project" and issuetype =Task and labels =recurring-task and "Business Service" in attributeValue("IT Responsible", "=", "currentUser()")

 

4.Final issue in Target Project

This is the view of the actual recurring/daily task. Additional checklist items can be added if needed.

After picking up the issue from Backlog, assignee can use the checklist and tick each item after completion to keep track of their work.

image.png

 

Results

Overall this was a simple setup, as our requirements were simple enough (i.e only 1 frequency of creation), but I like the approach and I think it could scale for further usages.

Any tips for improvements are welcomed, also questions.

 

Cheers,

Jimmy

2 comments

Hi Jimmy,

I noticed that you seem to have a rather old version of Checklist. We have released a new version with much more elaborated workflow functions and conditions. You may want to check it out in case something help you out.

https://okapya.atlassian.net/wiki/spaces/CHKDOC/pages/270598208/Modifying+a+Checklist+in+a+Workflow

Cheers,

Yves

Hi @Yves Riel,

 

These are just the print screens from my original documentation back when we did this (the setup hasn't changed).

We're on version: 4.0.2 in production now :)

Props for the cool new features.

 

Thanks,

Best Regards

Comment

Log in or Sign up to comment
Community showcase
Posted in Jira

The Jira Server Mobile App is here!

Hey Community! My name is James and I am a product manager on the Server Mobile team. I am excited to announce the new Jira Server Mobile apps for both iPhone and Android are now available. This is...

42 views 1 3
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you