Cycle Time

Tim Bäßler November 11, 2020

Hi guys,

I a looking for the JQL "Formula" to get the Cycle Time.  I think there is a posibilty to say start counting the Time when a ticket is taking "in progress" and stop when it is taken to another status like done. The goal is to get a list with the storys and the amount of time. I saw it in a past project but couldn't remeber how it was done. What i know is that it wasn't solved with a costly plugin ;-)

 

Can anybody help me?

Greetings from Germany

Tim

5 answers

1 vote
Jillian Ketterer December 9, 2020

One option for Cycle Time is to do the following using Jira Automation Rules:

  • Create a Progress Started rule that populates a field of the same name with a timestamp when the issue is moved to your In Progress status. Example syntax for field in automation rule: {{now.jiraDate}}

  • Create a Cycle Time rule that populates a field of the same name with the difference between the timestamp in Progress Started and "now", when the issue is moved to Done status. Example syntax for field in automation rule: {{now.diff(issue.Progress Started).businessDays.abs}}
1 vote
Bloompeak Support
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
November 11, 2020

Hi @Tim Bäßler ,

The info is implicitly available inside Jira and you can get it for each issue over Jira rest api as below. Then you need to parse the response, extract the data and make your calculation.

 JiraRestApi-History.png

Or, you can try Marketplace apps which do the parsing and calculation for you. You can try Status Time app developed by our team at Bloompeak. It provides reports on how much time spent on each status as well as status entry dates.

Once you enter your working calendar into the app, it takes your working schedule into account too. That is, "In Progress" time of an issue opened on Friday at 5 PM and closed on Monday at 9 AM, will be a few hours rather than 3 days. It has various other reports like assignee time, status entry dates, average/sum reports(eg. average in progress time per project).

Here is the online demo link, you can see it in action and try.

Hope it helps.

1 vote
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.
November 11, 2020

Hi @Tim Bäßler  -- Welcome to the Atlassian Community!

You cannot do that with a JQL filter and out-of-the-box Jira Cloud.  You can look at the built-in reports to see if they provide what you need, however they will not make a list of issues with cycle times.

As you note, you could purchase marketplace add-ons to do this.  Or, you could try several alternatives: regularly export issues to assess changes in a spreadsheet, use a webhook to push out changes and parse them with a log parser, use the REST API to pull out the change history, or build measurement using automation rules.

To build your own version using custom fields and automation rules, as follows:

  • Add custom fields for what you want to measure.  For example, start/end times, cycle time, etc.
  • Add automation rules, triggered on status transitions of interested to you
  • Capture the date/time of when the transition occurred
  • Add another rule to calculate cycle time at key points, such as when an issue moves to "done"

Here is some documentation on the automation rules if you choose to go that route: https://support.atlassian.com/jira-software-cloud/docs/automate-your-jira-cloud-processes-and-workflows/

Best regards,

Bill

0 votes
Mariana_Pryshliak_Saasjet
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
November 12, 2020

Hello @Tim Bäßler 

You can try Time between Statuses add-on, which generates a report on how long it takes an issue to move from one status to another. 

You can easily calculate Cycle time and get the time between the In Progress and Done statuses. 

I hope, it helps

Best regards, Mariana

0 votes
Emre Toptancı _OBSS_
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
November 11, 2020

Hello @Tim Bäßler ,

I am afraid what you are looking for is not available out-of-the-box in Jira. Each issue shows its own history under History tab but it is only for a single issue.

As for JQL, it is only used to filter issues. JQL cannot perform calculation or show issue histories. You can only add fields on issues as columns to the search screen. 

 

For a ready built solution that offers great fexibility and details, our team at OBSS built Time in Status app for this exact need. It is available for Jira Server, Cloud and Data Center.

Time in Status allows you to see how much time each issue spent on each status or assigned to each assignee as well as entry/exit dates for all statuses. You can calculate averages and sums of those durations grouped by issue fields you select. (For example see the average InProgress time per project and per issuetype). You can also combine statuses into consolidated columns to see metrics like Ticket Age, Cycle Time or Lead Time.

tisCloud_StatusSelection_Consolidated_output.png   tisCloud_MainPage_Chart_Pie_ExcludeMarked.png  tisCloud_IssueView_Chart_StackedColumn.png

The app calculates its reports using already existing Jira issue histories so when you install the app, you don't need to add anything to your issue workflows and you can get reports on your past issues as well.

The app has Custom calendar support which means you can get your reports based on a 24/7 calendar or your custom business calendar. (This one is important because a 24/7 calendar in most cases shows misleading data. For example an issue created at 16:00 on Friday and was resolved at 09:00 on next Monday seems to stay open for 2,5 days but in terms of business hours, it is only a few hours. You can see this using Time in Status by OBSS.)

Using Time in Status you can:

  • See how much time each issue spent on each status, assignee, user group and also see dates of status transitions.
  • Calculate averages and sums of those durations grouped by issue fields you select. (For example see average InProgress time per project and per issuetype.)
  • Export your data as XLS, XLSX or CSV.
  • Access data via REST API.
  • Visualize data with various chart types.

https://marketplace.atlassian.com/1211756

EmreT

Suggest an answer

Log in or Sign up to answer