Skip to main content
Bottleneck in your sprint? How to generate a Sprint Workload Report
Share on socials
A Jira Kanban board being prioritised
Kristian Walker
Kristian Walker
29th March, 2023
Cloud icon

Bottleneck in your sprint? How to generate a Sprint Workload Report

A Sprint Workload Report keeps your sprints running smoothly. Find out how to create this report out-of-the-box with Jira Cloud, and how to automate this reporting with ScriptRunner.
Your current sprint has been moving along nicely. Tasks are being ticked off your list, and you are on track to complete all work perfectly and on time.
Until day 9 when a teammate gets held up. On day 10, progress is still at a standstill. And by day 11, one problem has turned into three and is ready to throw the whole sprint off course because it turns out you’re over-relying on that one team-member who specialises in Gradle. As the scrum master or product owner, you wonder if you could have seen this coming? Can you prevent it from happening again? We've all been there, and we have good news.
The good news: we have a solution to help you keep your next sprint (and future sprints) running perfectly on time: you need a Sprint Workload Report. This report shows how many tasks each of your team members has to complete, so you can see where things are piling up and shutting down your sprint progression.
The great news: you can achieve this out-of-the-box with Jira Cloud.
The best news: you can automate this reporting with ScriptRunner for Jira Cloud and never get caught out again.
Let’s take a look at how.

How to generate a Sprint Workload Report in Jira Cloud

You can generate a Sprint Workload Report out-of-the-box with Jira Cloud by following these steps:
1. Create the following JQL query like below, replacing "SRCLOUD" with the project key of the project you want to monitor for bottlenecks.
1project = "SRCLOUD" AND sprint in openSprints () and statusCategory not in (Done)
2. Create a two-dimensional filter statistics gadget on a dashboard configured as below. Here’s a great refresher on how to build a dashboard.
Two Dimensional Filter Stats
3. Publish the gadget, and you will see a report that shows how many issues are assigned to each user in the sprint and the issue status.
Two-dimensional filter statistics gadget on a dashboard
Now you can see if anyone is bearing too much of the workload, and whether you need to more evenly distribute work among the team or identify areas to focus team training or recruitment.

How to generate a Sprint Workload Report with ScriptRunner

And now, here’s a script snippet to generate the same report using ScriptRunner:
2* This example script console script can be run in the in the script console inside ScriptRunner for Jira Cloud in order to see how many issues each user has assigned to them in a sprint. 
3* "All right, title and interest in this code snippet shall remain the exclusive intellectual property of Adaptavist Group Ltd and its affiliates. Customers with a valid ScriptRunner
4* license shall be granted a  non-exclusive, non-transferable, freely revocable right to use this code snippet only within their own instance of Atlassian products. This licensing notice cannot be removed or
5* amended and must be included in any circumstances where the code snippet is shared by You or a third party." 
8def projectKey = "<ProjectKeyHere>"; // Specify the project key here
10def jqlQuery = "project = ${projectKey} AND sprint in openSprints() and statusCategory not in (Done)";
12def searchRequest = get("/rest/api/2/search")
13        .queryString("jql", jqlQuery)
14        .queryString("fields", "status, assignee, key")
15        .asObject(Map);
17// Assert that the API call to the search API returned a success response        
18assert searchRequest.status == 200;
20// Extract the issue properies returned from the search results to a List
21def issues = (List<Map<String, Object>>) searchRequest.body.issues;
23// Call the returnSprintReport utility method passing it the list
26// A utility method that returns the sprint report information. 
27def returnSprintWorkloadReport(List<Map<String, Object>> issues) {
29// Loop over all issues and log out a report to the Logs detailing who is assigned to each issue and what status it is in.
30// as well as to construct an object of how many issues each assignee has in descending order including unassigned issues and display this information. 
31    return issues.groupBy { issue ->
32        println("${issue.key} is assigned to ${issue.fields.assignee?.displayName ?: 'Unassigned'} and is in the ${} status.")
33        ((Map<String, Map>) issue.fields).assignee?.displayName ?: 'Unassigned'
34    }.collectEntries { assignee, issueList ->
35        [(assignee): issueList.size()]
36    }.sort({ a, b -> b.value <=> a.value })
Some tips for using the snippet:
  • Line 8: specify the key of your Jira Project
  • Lines 12-15: make a call to the Jira Cloud Search Rest API to run the JQL query and return just the status assignee and issuekey fields for each issue.
Best practice: Specify only the fields you require as best practice to make the rest API call respond faster.
  • Line 18: with the rest API call completed successfully, it constructs a list of all the issues returned, but containing only the fields you specified, and passes this to your returnSprintWorkloadReport() method.
  • After you have run the script, click on the Logs tab below the script console to see the output produced by the script.
The returnSprintWorkloadReport() method works by looping over each issue returned from the search and displaying a message in the logs tag of who the issue is assigned to and its current status. We can then see how many issues are unassigned in the sprint and how many issues have been assigned to each user. This information is ordered by issues: most to least, so we can see who the bottleneck is at a glance.

New to ScriptRunner?

Get started today with a free 30-day trial.
Finding this post helpful? Share it with friends and colleagues.

Distributing your report

ScriptRunner can automatically share the report on your behalf, too. Here are a few recommendations, with script examples to help you make it possible:

Automating your Sprint Workload Report

The report you generated above is for a one-off query, ideal if you’re seeing a problem emerge in real time. But to help manage the distribution of work across the team, wouldn't it be more helpful to receive this information every week, perhaps on a Friday afternoon, to help plan resources for the coming week? Or maybe you'd like to share the results directly with your team at every sprint to help them think about any changes they could make to their ways of working when it comes to volunteering for PRs.
The frequency and timing of the report are up to you: with ScriptRunner’s Scheduled Jobs feature, you can choose the option best suited to you and your team.
Trigger your report to run daily at 9am to check the status every day, or once per week on a Tuesday, the second Wednesday of each month, or the 4th of every month: whichever suits your needs best. Use the “on this schedule” box to specify when you’d like the script to run. If you’ve never used ScriptRunner’s Scheduled Jobs before, you can learn everything you need to know in our Documentation.

Smoother sprint planning

Whether you run a one-off report in Jira, or take your Jira to the next level using automation on ScriptRunner, using a sprint workload report is a surefire way to identify any bottlenecks and keep your sprints running on track.
This blog post was inspired by a question submitted to our Is It Possible? webinar series. Thanks to Craeg for asking this question!

Quarterly Product Update webinar

Keep up to date with everything going on at ScriptRunner with our quarterly highlight reel of what's new and what's next.