=html_escape(s_('JiraService|%{jira_docs_link_start}Enable the Jira integration%{jira_docs_link_end} to view your Jira issues in GitLab.'))%{jira_docs_link_start: jira_docs_link_start.html_safe,jira_docs_link_end: '</a>'.html_safe}
| `username` | string | yes | The username of the user created to be used with GitLab/Jira. |
| `password` | string | yes | The password of the user created to be used with GitLab/Jira. |
| `active` | boolean | no | Activates or deactivates the service. Defaults to false (deactivated). |
| `jira_issue_transition_automatic` | boolean | no | Enable [automatic issue transitions](../user/project/integrations/jira.md#automatic-issue-transitions). Takes precedence over `jira_issue_transition_id` if enabled. Defaults to `false` |
| `jira_issue_transition_id` | string | no | The ID of one or more transitions for [custom issue transitions](../user/project/integrations/jira.md#custom-issue-transitions). Ignored if `jira_issue_transition_automatic` is enabled. Defaults to a blank string, which disables custom transitions. |
| `jira_issue_transition_automatic` | boolean | no | Enable [automatic issue transitions](../integration/jira/issues.md#automatic-issue-transitions). Takes precedence over `jira_issue_transition_id` if enabled. Defaults to `false` |
| `jira_issue_transition_id` | string | no | The ID of one or more transitions for [custom issue transitions](../integration/jira/issues.md#custom-issue-transitions). Ignored if `jira_issue_transition_automatic` is enabled. Defaults to a blank string, which disables custom transitions. |
@@ -11,10 +11,13 @@ You can integrate GitLab.com and Jira Cloud using the
app in the Atlassian Marketplace. The user configuring GitLab for Jira must have
[Maintainer](../../user/permissions.md) permissions in the GitLab namespace.
This method is recommended when using GitLab.com and Jira Cloud because data is synchronized in real-time. The DVCS connector updates data only once per hour. If you are not using both of these environments, use the [Jira DVCS Connector](dvcs.md) method.
This method is recommended when using GitLab.com and Jira Cloud because data is
synchronized in real-time. The DVCS connector updates data only once per hour.
If you are not using both of these environments, use the [Jira DVCS Connector](dvcs.md) method.
For a walkthrough of the integration with GitLab for Jira, watch [Configure GitLab Jira Integration using Marketplace App](https://youtu.be/SwR-g1s1zTo) on YouTube.
For a walkthrough of the integration with GitLab for Jira, watch
[Configure GitLab Jira Integration using Marketplace App](https://youtu.be/SwR-g1s1zTo) on YouTube.
1. Go to **Jira Settings > Apps > Find new apps**, then search for GitLab.
1. Click **GitLab for Jira**, then click **Get it now**, or go to the
...
...
@@ -47,8 +50,6 @@ After a namespace is added:
Support for syncing past branch and commit data [is planned](https://gitlab.com/gitlab-org/gitlab/-/issues/263240).
For more information, see [Usage](index.md#usage).
## Install the GitLab Jira Cloud application for self-managed instances **(FREE SELF)**
If your GitLab instance is self-managed, you must follow some
info:To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
---
# GitLab Jira Development panel integration **(FREE)**
> - [Moved](https://gitlab.com/gitlab-org/gitlab/-/issues/233149) to GitLab Free in 13.4.
The Jira Development panel integration allows you to reference Jira issues in GitLab, displaying
activity in the [Development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/)
in the issue.
It complements the [GitLab Jira integration](../../user/project/integrations/jira.md). You may choose
to configure both integrations to take advantage of both sets of features. See a
| In a merge request | Link to the MR is displayed in Development panel. |
| In a branch name | Link to the branch is displayed in Development panel. |
| In a commit message | Link to the commit is displayed in Development panel. |
| In a commit message with Jira Smart Commit format | Displays your custom comment or logged time spent and/or performs specified issue transition on merge. |
With this integration, you can access related GitLab merge requests, branches, and commits directly from a Jira issue, reflecting your work in GitLab. From the Development panel, you can open a detailed view and take actions including creating a new merge request from a branch. For more information, see [Usage](#usage).
This integration connects all GitLab projects to projects in the Jira instance in either:
- A top-level group. A top-level GitLab group is one that does not have any parent group itself. All
the projects of that top-level group, as well as projects of the top-level group's subgroups nesting
down, are connected.
- A personal namespace, which then connects the projects in that personal namespace to Jira.
This differs from the [Jira integration](../../user/project/integrations/jira.md), where the mapping is between one GitLab project and the entire Jira instance.
Additional features provided by the Jira Development Panel integration include:
- In a Jira issue, display relevant GitLab information in the [development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/), including related branches, commits, and merge requests.
- Use Jira [Smart Commits](https://confluence.atlassian.com/fisheye/using-smart-commits-960155400.html) in GitLab to add Jira comments, log time spent on the issue, or apply any issue transition.
- Showing pipeline, deployment, and feature flags in Jira issues.
For an overview of how to configure Jira Development panel integration, see [Agile Management - GitLab Jira Development panel integration](https://www.youtube.com/watch?v=VjVTOmMl85M&feature=youtu.be).
We recommend that a GitLab group maintainer or group owner, or instance administrator (in the case of
self-managed GitLab) set up the integration to simplify administration.
| If you use Jira on: | GitLab.com customers need: | GitLab self-managed customers need: |
|-|-|-|
| [Atlassian cloud](https://www.atlassian.com/cloud) | The [GitLab.com for Jira Cloud](https://marketplace.atlassian.com/apps/1221011/gitlab-com-for-jira-cloud?hosting=cloud&tab=overview) application installed from the [Atlassian Marketplace](https://marketplace.atlassian.com). This offers real-time sync between GitLab and Jira. | The [GitLab.com for Jira Cloud](https://marketplace.atlassian.com/apps/1221011/gitlab-com-for-jira-cloud?hosting=cloud&tab=overview), using a workaround process. See the documentation for [installing the GitLab Jira Cloud application for self-managed instances](connect-app.md#install-the-gitlab-jira-cloud-application-for-self-managed-instances) for more information. |
| Your own server | The Jira DVCS (distributed version control system) connector. This syncs data hourly. | The [Jira DVCS Connector](dvcs.md). |
Each GitLab project can be configured to connect to an entire Jira instance. That means one GitLab
project can interact with _all_ Jira projects in that instance, once configured. For:
- The [view Jira issues](issues.md#view-jira-issues) feature, you must associate a GitLab project with a
specific Jira project.
- Other features, you do not have to explicitly associate a GitLab project with any single Jira
project.
If you have a single Jira instance, you can pre-fill the settings. For more information, read the
documentation for [central administration of project integrations](../../user/admin_area/settings/project_integration_management.md).
To enable the Jira service in GitLab, you must:
1. Configure the project in Jira.
1. Enter the correct values in GitLab.
### Configure GitLab
> **Notes:**
>
> - The supported Jira versions are `v6.x`, `v7.x`, and `v8.x`.
> - In order to support Oracle's Access Manager, GitLab sends additional cookies
> to enable Basic Auth. The cookie being added to each request is `OBBasicAuth` with
> a value of `fromDialog`.
To enable the Jira integration in a project:
1. Go to the project's [Integrations page](../../user/project/integrations/overview.md#accessing-integrations) and select the
**Jira** service.
1. Select **Enable integration**.
1. Select **Trigger** actions.
This determines whether a mention of a Jira issue in GitLab commits, merge requests, or both,
should link the Jira issue back to that source commit/MR and transition the Jira issue, if
indicated.
1. To include a comment on the Jira issue when the above reference is made in GitLab, select
**Enable comments**.
1. To transition Jira issues when a [closing reference](../../user/project/issues/managing_issues.md#closing-issues-automatically) is made in GitLab,
select **Enable Jira transitions**.
1. Enter the further details on the page as described in the following table.
| Field | Description |
| ----- | ----------- |
| `Web URL` | The base URL to the Jira instance web interface which is being linked to this GitLab project. For example, `https://jira.example.com`. |
| `Jira API URL` | The base URL to the Jira instance API. Web URL value is used if not set. For example, `https://jira-api.example.com`. Leave this field blank (or use the same value of `Web URL`) if using **Jira on Atlassian cloud**. |
| `Username or Email` | Created in [configure Jira](dvcs.md#configure-jira-for-dvcs) step. Use `username` for **Jira Server** or `email` for **Jira on Atlassian cloud**. |
| `Password/API token` | Created in [configure Jira](dvcs.md#configure-jira-for-dvcs) step. Use `password` for **Jira Server** or `API token` for **Jira on Atlassian cloud**. |
1. To enable users to view Jira issues inside the GitLab project, select **Enable Jira issues** and
enter a Jira project key. **(PREMIUM)**
You can only display issues from a single Jira project within a given GitLab project.
WARNING:
If you enable Jira issues with the setting above, all users that have access to this GitLab project
are able to view all issues from the specified Jira project.
1. To enable creation of issues for vulnerabilities, select **Enable Jira issues creation from vulnerabilities**.
1. Select the **Jira issue type**. If the dropdown is empty, select refresh (**{retry}**) and try again.
1. To verify the Jira connection is working, select **Test settings**.
1. Select **Save changes**.
Your GitLab project can now interact with all Jira projects in your instance and the project now
displays a Jira link that opens the Jira project.
## Usage
After the integration is set up on GitLab and Jira, you can:
- Refer to any Jira issue by its ID in GitLab branch names, commit messages, and merge request
titles.
- See the linked branches, commits, and merge requests in Jira issues (merge requests are
called "pull requests" in Jira issues).
Jira issue IDs must be formatted in uppercase for the integration to work.
![Branch, Commit and Pull Requests links on Jira issue](img/jira_dev_panel_jira_setup_3.png)
Click the links to see your GitLab repository data.
![GitLab commits details on a Jira issue](img/jira_dev_panel_jira_setup_4.png)
![GitLab merge requests details on a Jira issue](img/jira_dev_panel_jira_setup_5.png)
For more information on using Jira Smart Commits to track time against an issue, specify an issue transition, or add a custom comment, see the Atlassian page [Using Smart Commits](https://confluence.atlassian.com/fisheye/using-smart-commits-960155400.html).
## Limitations
This integration is not supported on GitLab instances under a
info:To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
---
# GitLab Jira Development panel integration **(FREE)**
# Jira integrations **(FREE)**
> - [Moved](https://gitlab.com/gitlab-org/gitlab/-/issues/233149) to GitLab Free in 13.4.
If your organization uses [Jira](https://www.atlassian.com/software/jira) issues,
you can [migrate](../../user/project/import/jira.md) your issues from Jira and work
exclusively in GitLab. However, if you'd like to continue to use Jira, you can
integrate it with GitLab. GitLab offers two types of Jira integrations, and you
can use one or both depending on the capabilities you need.
The Jira Development panel integration allows you to reference Jira issues in GitLab, displaying
activity in the [Development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/)
in the issue.
## Compare Jira integrations
It complements the [GitLab Jira integration](../../user/project/integrations/jira.md). You may choose
to configure both integrations to take advantage of both sets of features. See a
| In a merge request | Link to the MR is displayed in Development panel. |
| In a branch name | Link to the branch is displayed in Development panel. |
| In a commit message | Link to the commit is displayed in Development panel. |
| In a commit message with Jira Smart Commit format | Displays your custom comment or logged time spent and/or performs specified issue transition on merge. |
For an overview, see [Agile Management - GitLab-Jira Basic Integration](https://www.youtube.com/watch?v=fWvwkx5_00E&feature=youtu.be).
With this integration, you can access related GitLab merge requests, branches, and commits directly from a Jira issue, reflecting your work in GitLab. From the Development panel, you can open a detailed view and take actions including creating a new merge request from a branch. For more information, see [Usage](#usage).
### Per-project Jira integration
This integration connects all GitLab projects to projects in the Jira instance in either:
This integration connects a single GitLab project to a Jira instance. The Jira instance
can be hosted by you or in [Atlassian cloud](https://www.atlassian.com/cloud):
-A top-level group. A top-level GitLab group is one that does not have any parent group itself. All
the projects of that top-level group, as well as projects of the top-level group's subgroups nesting
down, are connected.
- A personal namespace, which then connects the projects in that personal namespace to Jira.
-*If your installation uses GitLab.com and Jira Cloud,* use the
[GitLab for Jira app](connect-app.md).
-*If either your Jira or GitLab installation is self-managed,* use the
[Jira DVCS Connector](dvcs.md).
This differs from the [Jira integration](../../user/project/integrations/jira.md), where the mapping is between one GitLab project and the entire Jira instance.
### Jira development panel integration
## Configuration
The [Jira development panel integration](development_panel.md)
connects all GitLab projects under a group or personal namespace. When configured,
relevant GitLab information, including related branches, commits, and merge requests,
displays in the [development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/).
For an overview of how to configure Jira Development panel integration, see [Agile Management - GitLab Jira Development panel integration](https://www.youtube.com/watch?v=VjVTOmMl85M&feature=youtu.be).
### Direct feature comparison
We recommend that a GitLab group maintainer or group owner, or instance administrator (in the case of
self-managed GitLab) set up the integration to simplify administration.
| If you use Jira on: | GitLab.com customers need: | GitLab self-managed customers need: |
| [Atlassian cloud](https://www.atlassian.com/cloud) | The [GitLab.com for Jira Cloud](https://marketplace.atlassian.com/apps/1221011/gitlab-com-for-jira-cloud?hosting=cloud&tab=overview) application installed from the [Atlassian Marketplace](https://marketplace.atlassian.com). This offers real-time sync between GitLab and Jira. | The [GitLab.com for Jira Cloud](https://marketplace.atlassian.com/apps/1221011/gitlab-com-for-jira-cloud?hosting=cloud&tab=overview), using a workaround process. See the documentation for [installing the GitLab Jira Cloud application for self-managed instances](connect-app.md#install-the-gitlab-jira-cloud-application-for-self-managed-instances) for more information. |
| Your own server | The Jira DVCS (distributed version control system) connector. This syncs data hourly. | The [Jira DVCS Connector](dvcs.md). |
| Mention a Jira issue ID in a GitLab commit or merge request, and a link to the Jira issue is created. | Yes. | No. |
| Mention a Jira issue ID in GitLab and the Jira issue shows the GitLab issue or merge request. | Yes. A Jira comment with the GitLab issue or MR title links to GitLab. The first mention is also added to the Jira issue under **Web links**. | Yes, in the issue's Development panel. |
| Mention a Jira issue ID in a GitLab commit message and the Jira issue shows the commit message. | Yes. The entire commit message is displayed in the Jira issue as a comment and under **Web links**. Each message links back to the commit in GitLab. | Yes, in the issue's Development panel and optionally with a custom comment on the Jira issue using Jira [Smart Commits](https://confluence.atlassian.com/fisheye/using-smart-commits-960155400.html). |
| Mention a Jira issue ID in a GitLab branch name and the Jira issue shows the branch name. | No. | Yes, in the issue's [development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/). |
| Add Jira time tracking to an issue. | No. | Yes. Time can be specified using Jira Smart Commits. |
| Use a Git commit or merge request to transition or close a Jira issue. | Yes. Only a single transition type, typically configured to close the issue by setting it to Done. | Yes. Transition to any state using Jira Smart Commits. |
| Display a list of Jira issues. | Yes. **(PREMIUM)** | No. |
| Create a Jira issue from a vulnerability or finding. **(ULTIMATE)** | Yes. | No. |
## Authentication in Jira
## Usage
The process for configuring Jira depends on whether you host Jira on your own server or on
After the integration is set up on GitLab and Jira, you can:
-**Jira Server** supports basic authentication. When connecting, a **username and password** are
required. Connecting to Jira Server via CAS is not possible. For more information, read
how to [set up a user in Jira Server](jira_server_configuration.md).
-**Jira on Atlassian cloud** supports authentication through an API token. When connecting to Jira on
Atlassian cloud, an email and API token are required. For more information, read
[set up a user in Jira on Atlassian cloud](jira_cloud_configuration.md).
- Refer to any Jira issue by its ID in GitLab branch names, commit messages, and merge request
titles.
- See the linked branches, commits, and merge requests in Jira issues (merge requests are
called "pull requests" in Jira issues).
## Troubleshooting
Jira issue IDs must be formatted in uppercase for the integration to work.
If these features do not work as expected, it is likely due to a problem with the way the integration settings were configured.
![Branch, Commit and Pull Requests links on Jira issue](img/jira_dev_panel_jira_setup_3.png)
### GitLab is unable to comment on a Jira issue
Click the links to see your GitLab repository data.
Make sure that the Jira user you set up for the integration has the
correct access permission to post comments on a Jira issue and also to transition
the issue, if you'd like GitLab to also be able to do so.
Jira issue references and update comments do not work if the GitLab issue tracker is disabled.
![GitLab commits details on a Jira issue](img/jira_dev_panel_jira_setup_4.png)
### GitLab is unable to close a Jira issue
![GitLab merge requests details on a Jira issue](img/jira_dev_panel_jira_setup_5.png)
Make sure the `Transition ID` you set within the Jira settings matches the one
your project needs to close an issue.
For more information on using Jira Smart Commits to track time against an issue, specify an issue transition, or add a custom comment, see the Atlassian page [Using Smart Commits](https://confluence.atlassian.com/fisheye/using-smart-commits-960155400.html).
Make sure that the Jira issue is not already marked as resolved; that is,
the Jira issue resolution field is not set. (It should not be struck through in
Jira lists.)
## Limitations
### CAPTCHA
This integration is not supported on GitLab instances under a
info:To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
---
# Jira integration issue management **(FREE)**
By now you should have [configured Jira](development_panel.md#configuration) and enabled the
[Jira service in GitLab](development_panel.md#configure-gitlab). If everything is set up correctly
you should be able to reference and close Jira issues by just mentioning their
ID in GitLab commits and merge requests.
Jira issue IDs must be formatted in uppercase for the integration to work.
## Reference Jira issues
When GitLab project has Jira issue tracker configured and enabled, mentioning
Jira issues in GitLab automatically adds a comment in Jira issue with the
link back to GitLab. This means that in comments in merge requests and commits
referencing an issue, `PROJECT-7` for example, adds a comment in Jira issue in the
format:
```plaintext
USER mentioned this issue in RESOURCE_NAME of [PROJECT_NAME|LINK_TO_COMMENT]:
ENTITY_TITLE
```
-`USER` A user that mentioned the issue. This is the link to the user profile in GitLab.
-`LINK_TO_THE_COMMENT` Link to the origin of mention with a name of the entity where Jira issue was mentioned.
-`RESOURCE_NAME` Kind of resource which referenced the issue. Can be a commit or merge request.
-`PROJECT_NAME` GitLab project name.
-`ENTITY_TITLE` Merge request title or commit message first line.
![example of mentioning or closing the Jira issue](img/jira_issue_reference.png)
For example, the following commit references the Jira issue with `PROJECT-1` as its ID:
```shell
git commit -m"PROJECT-1 Fix spelling and grammar"
```
## Close Jira issues
Jira issues can be closed directly from GitLab by using trigger words in
commits and merge requests. When a commit which contains the trigger word
followed by the Jira issue ID in the commit message is pushed, GitLab
adds a comment in the mentioned Jira issue and immediately closes it (provided
the transition ID was set up correctly).
There are currently three trigger words, and you can use either one to achieve
the same goal:
-`Resolves PROJECT-1`
-`Closes PROJECT-1`
-`Fixes PROJECT-1`
where `PROJECT-1` is the ID of the Jira issue.
Note the following:
- Only commits and merges into the project's default branch (usually `master`)
close an issue in Jira. You can change your project's default branch under
1. To display the most recently updated issues first, click **Last updated**.
1. In GitLab versions 13.10 and later, you can view [individual Jira issues](#view-a-jira-issue).
Issues are grouped into tabs based on their [Jira status](https://confluence.atlassian.com/adminjiraserver070/defining-status-field-values-749382903.html):
- The **Open** tab displays all issues with a Jira status in any category other than Done.
- The **Closed** tab displays all issues with a Jira status categorized as Done.
- The **All** tab displays all issues of any status.
## View a Jira issue
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/299832) in [GitLab Premium](https://about.gitlab.com/pricing/) 13.10 behind a feature flag, disabled by default.
> - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/299832) in [GitLab Premium](https://about.gitlab.com/pricing/) 13.11.
When viewing the [Jira issues list](#view-jira-issues), select an issue from the
To refine the list of issues, use the search bar to search for any text
contained in an issue summary (title) or description.
You can also filter by labels, status, reporter, and assignee using URL parameters.
Enhancements to be able to use these through the user interface are [planned](https://gitlab.com/groups/gitlab-org/-/epics/3622).
- To filter issues by `labels`, specify one or more labels as part of the `labels[]`
parameter in the URL. When using multiple labels, only issues that contain all specified
labels are listed. `/-/integrations/jira/issues?labels[]=backend&labels[]=feature&labels[]=QA`
- To filter issues by `status`, specify the `status` parameter in the URL.
`/-/integrations/jira/issues?status=In Progress`
- To filter issues by `reporter`, specify a reporter's Jira display name for the
`author_username` parameter in the URL. `/-/integrations/jira/issues?author_username=John Smith`
- To filter issues by `assignee`, specify their Jira display name for the
`assignee_username` parameter in the URL. `/-/integrations/jira/issues?assignee_username=John Smith`
## Automatic issue transitions
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/...) in GitLab 13.10.
In this mode the referenced Jira issue is transitioned to the next available status with a category of "Done".
See the [Configure GitLab](development_panel.md#configure-gitlab) section, check the **Enable Jira transitions** setting and select the **Move to Done** option.
## Custom issue transitions
For advanced workflows you can specify custom Jira transition IDs.
See the [Configure GitLab](development_panel.md#configure-gitlab) section, check the **Enable Jira transitions** setting, select the **Custom transitions** option, and enter your transition IDs in the text field.
If you insert multiple transition IDs separated by `,` or `;`, the issue is moved to each state, one after another, using the given order. If a transition fails the sequence is aborted.
To see the transition IDs on Jira Cloud, edit a workflow in the **Text** view.
The transition IDs display in the **Transitions** column.
On Jira Server you can get the transition IDs in either of the following ways:
1. By using the API, with a request like `https://yourcompany.atlassian.net/rest/api/2/issue/ISSUE-123/transitions`
using an issue that is in the appropriate "open" state
1. By mousing over the link for the transition you want and looking for the
"action" parameter in the URL
Note that the transition ID may vary between workflows (for example, bug vs. story),
even if the status you are changing to is the same.
## Disabling comments on Jira issues
You can continue to have GitLab cross-link a source commit/MR with a Jira issue while disabling the comment added to the issue.
See the [Configure GitLab](development_panel.md#configure-gitlab) section and uncheck the **Enable comments** setting.
info:To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
redirect_to:'../../../integration/jira/index.md'
---
# GitLab Jira integration **(FREE)**
This document was moved to [another location](../../../integration/jira/index.md).
You can use Jira to track work implemented in GitLab. The Jira integration with GitLab makes the
process of working across these systems more efficient.
The GitLab Jira integration, available in every GitLab project by default, allows you to connect
to any Jira instance, whether on Atlassian cloud or self-managed.
You can also install the [Jira Development Panel integration](../../../integration/jira/index.md).
For more information about the differences between the two integrations, see
[Jira integrations](jira_integrations.md).
After you set up this integration, you can cross-reference activity in the GitLab project with any
of your projects in Jira. This includes the ability to close or transition Jira issues when work is
completed in GitLab and:
- Mention a Jira issue ID in a commit message or MR (merge request) and:
- GitLab links to the Jira issue.
- The Jira issue adds a comment with details and a link back to the activity in GitLab.
- Mention that a commit or MR resolves or closes a specific Jira issue and when it's merged to the default branch:
- The GitLab MR displays a note that it closed the Jira issue. Prior to the merge, MRs indicate which issue they close.
- The Jira issue shows the activity and is closed or otherwise transitioned as specified in your GitLab settings.
- Run a pipeline on an MR linked to a Jira issue:
- The Jira issue shows the current pipeline status (in the sidebar as "builds").
- Deploy to an environment from an MR linked to a Jira issue:
- The Jira issue shows the status of the deployment (in the sidebar as "deployments").
- Create or modify a feature flag that mentions a Jira issue in its description:
- The Jira issue shows the details of the feature-flag (in the sidebar as "feature flags").
- View a list of Jira issues directly in GitLab. **(PREMIUM)**
- Create a Jira issue from a vulnerability. **(ULTIMATE)**
Additional features provided by the Jira Development Panel integration include:
- In a Jira issue, display relevant GitLab information in the [development panel](https://support.atlassian.com/jira-software-cloud/docs/view-development-information-for-an-issue/), including related branches, commits, and merge requests.
- Use Jira [Smart Commits](https://confluence.atlassian.com/fisheye/using-smart-commits-960155400.html) in GitLab to add Jira comments, log time spent on the issue, or apply any issue transition.
- Showing pipeline, deployment, and feature flags in Jira issues.
Jira Server supports basic authentication. When connecting, a **username and password** are
required. Connecting to Jira Server via CAS is not possible. For more information, see
[set up a user in Jira Server](../../../integration/jira/jira_server_configuration.md).
#### Jira on Atlassian cloud
Jira on Atlassian cloud supports authentication through an API token. When connecting to Jira on
Atlassian cloud, an **email and API token** are required. For more information, see
[set up a user in Jira on Atlassian cloud](../../../integration/jira/jira_cloud_configuration.md).
### Configure GitLab
> **Notes:**
>
> - The supported Jira versions are `v6.x`, `v7.x`, and `v8.x`.
> - In order to support Oracle's Access Manager, GitLab sends additional cookies
> to enable Basic Auth. The cookie being added to each request is `OBBasicAuth` with
> a value of `fromDialog`.
To enable the Jira integration in a project:
1. Go to the project's [Integrations page](overview.md#accessing-integrations) and select the
**Jira** service.
1. Select **Enable integration**.
1. Select **Trigger** actions.
This determines whether a mention of a Jira issue in GitLab commits, merge requests, or both,
should link the Jira issue back to that source commit/MR and transition the Jira issue, if
indicated.
1. To include a comment on the Jira issue when the above reference is made in GitLab, select
**Enable comments**.
1. To transition Jira issues when a [closing reference](../issues/managing_issues.md#closing-issues-automatically) is made in GitLab,
select **Enable Jira transitions**.
1. Enter the further details on the page as described in the following table.
| Field | Description |
| ----- | ----------- |
| `Web URL` | The base URL to the Jira instance web interface which is being linked to this GitLab project. For example, `https://jira.example.com`. |
| `Jira API URL` | The base URL to the Jira instance API. Web URL value is used if not set. For example, `https://jira-api.example.com`. Leave this field blank (or use the same value of `Web URL`) if using **Jira on Atlassian cloud**. |
| `Username or Email` | Created in [configure Jira](#configure-jira) step. Use `username` for **Jira Server** or `email` for **Jira on Atlassian cloud**. |
| `Password/API token` | Created in [configure Jira](#configure-jira) step. Use `password` for **Jira Server** or `API token` for **Jira on Atlassian cloud**. |
1. To enable users to view Jira issues inside the GitLab project, select **Enable Jira issues** and
enter a Jira project key. **(PREMIUM)**
You can only display issues from a single Jira project within a given GitLab project.
WARNING:
If you enable Jira issues with the setting above, all users that have access to this GitLab project
are able to view all issues from the specified Jira project.
1. To enable creation of issues for vulnerabilities, select **Enable Jira issues creation from vulnerabilities**.
1. Select the **Jira issue type**. If the dropdown is empty, select refresh (**{retry}**) and try again.
1. To verify the Jira connection is working, select **Test settings**.
1. Select **Save changes**.
Your GitLab project can now interact with all Jira projects in your instance and the project now
displays a Jira link that opens the Jira project.
#### Automatic issue transitions
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/...) in GitLab 13.10.
In this mode the referenced Jira issue is transitioned to the next available status with a category of "Done".
See the [Configure GitLab](#configure-gitlab) section, check the **Enable Jira transitions** setting and select the **Move to Done** option.
#### Custom issue transitions
For advanced workflows you can specify custom Jira transition IDs.
See the [Configure GitLab](#configure-gitlab) section, check the **Enable Jira transitions** setting, select the **Custom transitions** option, and enter your transition IDs in the text field.
If you insert multiple transition IDs separated by `,` or `;`, the issue is moved to each state, one after another, using the given order. If a transition fails the sequence is aborted.
To see the transition IDs on Jira Cloud, edit a workflow in the **Text** view.
The transition IDs display in the **Transitions** column.
On Jira Server you can get the transition IDs in either of the following ways:
1. By using the API, with a request like `https://yourcompany.atlassian.net/rest/api/2/issue/ISSUE-123/transitions`
using an issue that is in the appropriate "open" state
1. By mousing over the link for the transition you want and looking for the
"action" parameter in the URL
Note that the transition ID may vary between workflows (for example, bug vs. story),
even if the status you are changing to is the same.
#### Disabling comments on Jira issues
You can continue to have GitLab cross-link a source commit/MR with a Jira issue while disabling the comment added to the issue.
See the [Configure GitLab](#configure-gitlab) section and uncheck the **Enable comments** setting.
## Jira issues
By now you should have [configured Jira](#configure-jira) and enabled the
[Jira service in GitLab](#configure-gitlab). If everything is set up correctly
you should be able to reference and close Jira issues by just mentioning their
ID in GitLab commits and merge requests.
Jira issue IDs must be formatted in uppercase for the integration to work.
### Reference Jira issues
When GitLab project has Jira issue tracker configured and enabled, mentioning
Jira issues in GitLab automatically adds a comment in Jira issue with the
link back to GitLab. This means that in comments in merge requests and commits
referencing an issue, `PROJECT-7` for example, adds a comment in Jira issue in the
format:
```plaintext
USER mentioned this issue in RESOURCE_NAME of [PROJECT_NAME|LINK_TO_COMMENT]:
ENTITY_TITLE
```
-`USER` A user that mentioned the issue. This is the link to the user profile in GitLab.
-`LINK_TO_THE_COMMENT` Link to the origin of mention with a name of the entity where Jira issue was mentioned.
-`RESOURCE_NAME` Kind of resource which referenced the issue. Can be a commit or merge request.
-`PROJECT_NAME` GitLab project name.
-`ENTITY_TITLE` Merge request title or commit message first line.
![example of mentioning or closing the Jira issue](img/jira_issue_reference.png)
For example, the following commit references the Jira issue with `PROJECT-1` as its ID:
```shell
git commit -m"PROJECT-1 Fix spelling and grammar"
```
### Close Jira issues
Jira issues can be closed directly from GitLab by using trigger words in
commits and merge requests. When a commit which contains the trigger word
followed by the Jira issue ID in the commit message is pushed, GitLab
adds a comment in the mentioned Jira issue and immediately closes it (provided
the transition ID was set up correctly).
There are currently three trigger words, and you can use either one to achieve
the same goal:
-`Resolves PROJECT-1`
-`Closes PROJECT-1`
-`Fixes PROJECT-1`
where `PROJECT-1` is the ID of the Jira issue.
Note the following:
- Only commits and merges into the project's default branch (usually `master`)
close an issue in Jira. You can change your project's default branch under
1. To display the most recently updated issues first, click **Last updated**.
1. In GitLab versions 13.10 and later, you can view [individual Jira issues](#view-a-jira-issue).
Issues are grouped into tabs based on their [Jira status](https://confluence.atlassian.com/adminjiraserver070/defining-status-field-values-749382903.html):
- The **Open** tab displays all issues with a Jira status in any category other than Done.
- The **Closed** tab displays all issues with a Jira status categorized as Done.
- The **All** tab displays all issues of any status.
#### View a Jira issue
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/299832) in [GitLab Premium](https://about.gitlab.com/pricing/) 13.10 behind a feature flag, disabled by default.
> - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/299832) in [GitLab Premium](https://about.gitlab.com/pricing/) 13.11.
When viewing the [Jira issues list](#view-jira-issues), select an issue from the
info:To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
redirect_to:'../../../integration/jira/index.md'
---
# Jira integrations **(FREE)**
This document was moved to [another location](../../../integration/jira/index.md).
If your organization uses [Jira](https://www.atlassian.com/software/jira) issues,
you can [migrate](../../../user/project/import/jira.md) your issues from Jira and work
exclusively in GitLab.
However, if you'd like to continue to use Jira, you can integrate it with GitLab.
There are two ways to use GitLab with Jira:
-[Jira integration](jira.md). Connect a GitLab project
to a Jira instance. The Jira instance can be hosted by you or in [Atlassian cloud](https://www.atlassian.com/cloud).
-[Jira Development panel integration](../../../integration/jira_development_panel.md).
Connect all GitLab projects under a group or personal namespace.
The integration you choose depends on the capabilities you require.
| Mention a Jira issue ID in GitLab and a link to the Jira issue is created. | Yes. | No. |
| Mention a Jira issue ID in GitLab and the Jira issue shows the GitLab issue or merge request. | Yes. A Jira comment with the GitLab issue or MR title links to GitLab. The first mention is also added to the Jira issue under **Web links**. | Yes, in the issue's Development panel. |
| Mention a Jira issue ID in a GitLab commit message and the Jira issue shows the commit message. | Yes. The entire commit message is displayed in the Jira issue as a comment and under **Web links**. Each message links back to the commit in GitLab. | Yes, in the issue's Development panel and optionally with a custom comment on the Jira issue using Jira Smart Commits. |
| Mention a Jira issue ID in a GitLab branch name and the Jira issue shows the branch name. | No. | Yes, in the issue's Development panel. |
| Add Jira time tracking to an issue. | No. | Yes. Time can be specified using Jira Smart Commits. |
| Use a Git commit or merge request to transition or close a Jira issue. | Yes. Only a single transition type, typically configured to close the issue by setting it to Done. | Yes. Transition to any state using Jira Smart Commits. |
| Display a list of Jira issues. | Yes. **(PREMIUM)** | No. |
| Create a Jira issue from a vulnerability or finding. **(ULTIMATE)** | Yes. | No. |
<!-- This redirect file can be deleted after <2021-07-13>. -->
<!-- Before deletion, see: https://docs.gitlab.com/ee/development/documentation/#move-or-rename-a-page -->