JIRA SERVER STARTING FROM 4.5.1
This article shows how to sync statuses with the Exalate external script.
This page describes how to synchronize issue statuses between two JIRA Instances bi-directionally.
JIRA requires that status is updated by progressing an issue through the different workflow steps. This can be done in different ways:
- Manual modeling every step - Unified workflow using static transitions
- Using any to one type of transitions - Unified workflow using global transitions
- Automatic progressing to the right status using advanced groovy scripting
A third approach is the one explained in this document, where the processor tries to find the shortest path to the appropriate status automatically, based on the mapping set in the script.
Let's consider you already have the Connection configured between two JIRA Instances.
Now you need to configure status synchronization:
Create files from the Exalate public repository
We store external scripts for Jira Server in a public repository. Copy the code from the repositories below and create .groovy files. You must keep the file name as below.
Upload the files to the $JIRA_HOME/scripts directory
Configure Sync Rules with the scripts provided below:Add the snippets below to the end of the Sync Rules.
If statuses are the same on both sides, use this code:
If the statuses are different, use this code with your status mapping
Status.receive has the following parameters:
useRemoteStatusByDefault = true
Use the remote status by default.
workflowMapping = [:]
Defines the status mapping as on the example below
resolutionMapping = [:]
Defines resolution mapping as on the example below