2. AgileSparks
2 |
❖ We help companies improve by adopting agile principles and
practices
❖ We provide training and coaching to all organizational levels,
from high management to developers
❖ Our team consists of Agile professionals with diverse expertise
❖ Global solutions – US, Israel, India
6. What are we going to talk about?
• Helping teams become more productive
• Cataloging issues for quicker search
• Achieving much more details about the issues life cycle
• Making the tool work for the users
Individuals and interactions
over
processes and tools
From the Agile Manifesto
8. • Big data of API commands to monitor/change almost anything in Jira
• Ability to create JQL* queries, with some scripting even recursive queries
• For example: query to find all epics with certain component and afterwards a query
to get all the children of those epics
• Ready to use “Postman Collections” with all REST API commands
• Provides some operations that are not allowed from the Jira UI
• Easy commands with user/password to get data (cloud: email/API key)
• Important Note: there are 2 different versions of API:
• Server / Data Center versions uses up to version 2
• Cloud uses up to version 3
* JQL - Jira Query Language
9. There are 3 ways of operating with Jira’s REST API:
1. Operating a script only when needed
2. Operating a script by schedule (daily/every hour/etc.)
3. Operating scripts by a listener
10. Webhooks
Webhooks enables you to get
notifications about changes in Jira
once it happens.
For example: you can get a
notification for creation / editing /
deletion of issues / sprint / boards
and more.
To get the data you need to setup
a listener to receive the data and
operate the script.
11. • Operates from within Jira
• Available for both Server and Cloud versions:
• For cloud you must upload the plugin to the marketplace and define as
private
• Jira’s code is in Java and that’s the preferred plugin language
• Today’s tools allows you to create with different language and transform the
code to Java
• Different from REST API way, a plugin can change the process itself
Jira Plugin
15. Automation for Jira
Created by Code Barrel
One of the top recommended apps in Atlassian’s marketplace
Code Barrel was acquired by Atlassian on Oct, 2019
Recently had been implemented in Jira Cloud as a built-in feature
16. Automation for Jira
Disadvantages:
• Advance functions has a learning curve
• Atlassian’s pricing can vary
Limited
You cannot do everything you wish to do in it
Especially when comparing to ScriptRunner that can do a lot!
17. Automation for Jira
Advantages:
• Any user in a project manager role can define automations
• Automations can be assigned to a single project or shared with many
• Easy debugging with mail notifications for every automation failure
Super Easy to use
20. Automation for Jira - Basic Functionalities
Filter
Example:
Tip!
Use “Related issues condition” if you want to filter by
parents/children data.
For example: continue automation if the parent epic of this
issue contains version “1.1” in the “fix version” field.
24. Automation for Jira - Basic Functionalities
Action
Rarely used but important actions:
Useful action when need to use a
value that was changed during the
same automation, see example:
X = 5
Y = 15 (3 times value of X)
During automation:
X 8
If we don’t use “re-fetch”:
Y (5*3)=15
If we use “re-fetch”:
Y (8*3) = 24
Useful actions when already using
ScriptRunner or using a listener
25. Automation for Jira - Basic Functionalities
Action
There is a possibility to use json
when editing issues.
2 cases that you would want to
use it:
1. When you are creating more
than 1 automation that should
edit the same fields or close to
the same fields
2. When the field you try to
change is not in the list of
fields
26. Automation for Jira - Advanced Functions
Smart Values
Smart Values
The ability to use fields values or part of them
For example:
27. Automation for Jira - Advanced Functions
Math Functions
Math Functions
Doing math calculation using fields values
For example:
28. Automation for Jira - Advanced Functions
Default Values
Default Values
Use default values in case a field is empty
May reduce failure of automations
For example:
| 0
29. Automation for Jira - Advanced Functions
And More…
Join values from a “list” field
Calculating time diff between 2
values
Converting a field into json format
Editing functions for text fields
And more…
{{issue.fixVersions.name.join(" - ")}}
// Produces “Version 2.0 – Version 3.0”
{{now.diff(issue.created).days}}
// Produces “3d 5h”
{{issue.fixVersions.name.asJsonObject("title").asJsonArray}}
// Produces
[{ "title": "Version 2.0" },{ "title": "Version 3.0" }]
{{issue.summary.toLowerCase().substring(0, 10).concat("!!")}}
31. Automation for Jira - Basic Functionalities
Branch Rule / Related Issues
• Enables editing related issues
and instead of the issue that
triggered the automation rule
• Can be used to copy data from
the trigger issue into the
related issues
Note!
Branch is not available on
“Automation for Jira – Server lite”
36. Tips
1. Create an easy to view changes
When working on custom fields changes you may not always get the result
you expected. Use a dummy issue to check changes and make the change on
the “Description” field which is easy to view
2. Work Smart
If you are working with custom fields id’s, change the URL of the issue
From: <<URL>>/browse/YYY-123
To: <<URL>>/rest/api/2/issue/YYY-123
You’ll immediately get all the issue’s fields and ids.
37. Tips
3. Change a direction
Reached a dead end result? Throw away you line of thought and think of
a different way to approach the automation.
In most cases it works, in others not – the app is still a bit limited.
4. Recursion
You can create recursive automations, meaning: after one automation
rule run make a second automation rule run automatically.
(by default the option is disabled in the rule details to prevent infinite loop)
38. Automation for Jira
Available Options
• Jira Cloud:
• On basic plan you get total of 500 automation runs
• On premium plan you get 1000 automation runs for every paid user
• Purchasing – price is yet to be published (3 months free addiction)
• Jira Server / Data Center:
• Automation Lite – free plugin with restricted functionalities
• Full version – 30 days trial with full functionalities