Plugin Information |
---|
View Jira on the plugin site for more information. |
Older versions of this plugin may not be safe to use. Please review the following warnings before using an older version:
TOC:
Using JIRA REST API
This plugin has an optional feature to update JIRA issues with a back pointer to Jenkins build pages. This allows the submitter and watchers to quickly find out which build they need to pick up to get the fix.
JIRA Issue links in build Changelog
When you configure your JIRA site in Jenkins, the plugin will automatically hyperlink all matching issue names to JIRA.
If you have additionally provided username/password to JIRA, the hyperlinks will also contain tooltips with the issue summary.
Updating JIRA issues with back pointers
If you also want to use this feature, you need to supply a valid user id/password. If you need the comment only to be visible to a certain JIRA group, e.g. Software Development, enter the groupname.
Now you also need to configure jobs. I figured you might not always have write access to the JIRA (say you have a Jenkins build for one of the Apache commons project that you depend on), so that's why this is optional.
And the following screen shows how JIRA issue is updated:
By taking advantages of Jenkins' fingerprint feature, when your other projects that depend on this project pick up a build with a fix, those build numbers can also be recorded in JIRA.
This is quite handy when a bug is fixed in one of the libraries, yet the submitter wants a fix in a different project. This happens often in my work, where a bug is reported against JAX-WS but the fix is in JAXB.
For curious mind, see this thread for how this works behind the scene.
Referencing JIRA Release version
To reference JIRA Release versions in your build, you can pull these releases directly from JIRA by adding the JIRA Release Version Parameter.
This can be useful for generating release notes, trigerring parameterized build, etc.
Generating Release Notes
You can also generate release notes to be used during your build. These notes can be retrieved from an environment variable. See the Maven Project Plugin for the environment variables found within the POM.
After your build has run, you can also have the plugin mark a release as resolved. This typically will be a release you specified in your Build Parameters.
The plugin can also move certain issues matching a JQL query to a new release version.
Sample usage of generated Release Notes:
JIRA Authentication & Permissions required
Note: As a rule of thumb, you should be always using a service account (instead of a personal account) to integrate Jenkins with JIRA.
Make sure that the JIRA user used by Jenkins has enough permissions to execute its actions. You can do that via JIRA Permission Helper tool.
- For creating JIRA issues, the user has to be able to Create Issues in the specified project
- If you additionally enter assignee or component field values, make sure that:
- both of the fields are assigned to the corresponding JIRA Screen
- the JIRA user is Assignable in the project
- the Jenkins JIRA user can Assign issues
JIRA Cloud
In Atlassian JIRA Cloud, it's not possible to create a user without an email, so you need to create API token.
Then create a global Jenkins credential, where you put Atlassian ID email as username and API token as password.
You can check if your API token works correctly by getting a correct JSON issue response with this command (where TEST-1 is an example issue in your project):
$ curl -X GET -u <email>:<API token> -H "Content-Type: application/json" https://<YourCloudInstanceName>.atlassian.net/rest/api/latest/issue/TEST-1
Also make sure that CAPTCHA is not triggered for your user as this will prevent the API token to work - see CAPTCHA section in Atlassian REST API documentation.
System properties
Property Name | Functionality Change |
---|---|
-Dhudson.plugins.jira.JiraMailAddressResolver.disabled=true | Use to disable resolving user email from JIRA usernames. Currently there is no option for this in UI. |
Related Resources
- Check also the Marvelution Jira Hudson Integration which provides a two-way solution Hudson->JIRA and JIRA->Hudson
- Hudson integration for JIRA adds Hudson information to JIRA.
- The Subversion JIRA plugin also allows recording of scm changes to JIRA issues (for other SCMs there are similar plugins)
- For JIRA Workflow (Pipeline) plugin compatibility see COMPATIBILITY.md
Releases
Version 3.0.11 (2019-11-21)
Version 3.0.10 (2019-09-26)
- dependencies cleanup (remove dependency on org.codehaus.jackson:*)
Version 3.0.9 (2019-08-21)
Version 3.0.8 (2019-06-28)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-58244 | JIRA Site at folder level doesn't show credentials for non-admin users | Closed | |
JENKINS-57664 | On Release of a Version recieve a Null Pointer exception | Closed | |
Version 3.0.7 (2019-05-01)
Version 3.0.6 (2019-03-30)
Version 3.0.5 (2018-11-07)
Version 3.0.4 (2018-10-26)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-54144 | Job fails as JiraSCMListsener/JiraSite potentially creating Executor with 0 threads | Closed | |
Version 3.0.3 (2018-10-16)
Version 3.0.2 (2018-09-25)
Version 3.0.1 (2018-08-22)
Version 3.0.0 (2018-05-20)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-51312 | Jira plugin core 2.60.1 | Closed | |
JENKINS-51310 | Update JIRA plugin to use jackson2-api-plugin | Closed | |
Version 2.5.2 (2018-05-04)
Version 2.4.2 (2017-08-08)
Version 2.4 (2017-08-03)
Version 2.3.1 (2017-05-23)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-40571 | JiraVersionCreatorBuilder fields missing in post-build form | Closed | |
Version 2.3 (2016-12-19)
Version 2.2.1 (2016-03-26)
Version 2.2 (2016-02-20)
- Split each SCM changes in paragraphs
- support release candidates (RCs) via Maven ComparableVersion
- Console logging improvements in various places
- JiraEnvironmentVariableBuilder support
- Support adding labels to updated issues
- (optionally) add scm entry change date and time to description in JIRA tickets
Version 2.1 (2015-11-18)
- Bumped Jenkins Core to LTS v. 1.609.3
- Added dependencies: mailer-plugin, matrix-plugin
- Removed dependencies: maven-plugin
Version 2.0.3 (2015-10-26)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-30682 | Ticket creation fails when no components in JIRA project exist / JIRA rejects empty component list | Closed | |
Version 2.0.2 (2015-09-15)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-30408 | JIRA REST API requests lead to 404 (not found) | Closed | |
JENKINS-30333 | Thread Leak due to use of deprecated JiraSize.createSession | Closed | |
Version 2.0.1 (2015-09-10)
T | Key | Summary | Status |
---|---|---|---|
JENKINS-30242 | Update to 1.13.2 breaks global configuration submission when jira-plugin installed | Closed | |
Version 2.0 (2015-09-02)
Incompatbile change: switch from JIRA RPC SOAP to JIRA REST API communication - the former has been deprecated and dropped since JIRA v.7.0.
Version 1.41 (2015-06-10)
Version 1.39 (Oct 6, 2013)
- Ability only to comment issue without processing of workflow (pull #38)
Version 1.38 (Aug 23, 2013)
- Post build step to create new JIRA version (pull #30)
Version 1.37 (Jun 21, 2013)
- Error with empty alternative url issue #18229
Version 1.35 (Jul 29, 2012)
- Prevents multiple comments on one issue for matrix builds. (PR #13)
Version 1.34 (Jun 11, 2012)
- Fix NPE when Jenkins user does not have access to perform any workflow actions JENKINS-13998
Version 1.33 (Jun 1, 2012)
- Support workflow steps as build actions and/or post-build notifiers JENKINS-13652
Version 1.32 (May 15, 2012)
- Option to show archived versions.
Version 1.31 (May 1, 2012)
- Add JiraIssueMigrator - a post build action that will move issues to a new fixVersion based on a JQL query.
- Add Additional filtering of issues to be included in the release notes. Defaults to 'status in (Resolved, Closed)'
Version 1.30 (April 25, 2012)
- Add build parameter that providers a drop-down with JIRA release versions
Add a build wrapper that will assemble release notes based on issues in the release version and store it in an environment variable
# Issue Type - [JIRA-123] Issue summary - [JIRA-124] Another Issue summary # Another Issue Type - [JIRA-321] Yet another issue summary
- Add a post-build action that will mark a version as released in JIRA
Version 1.29 (August 25, 2011)
- JENKINS-10817 Jira-plugin should add the overall build result to the issue's comment
- Include revisions also for non-subversion plugins; include revisions also if we don't have a repository browser
- Defined a new parameter type for parameterized builds that allow you to select a JIRA ticket (from the result of a JQL query)
Version 1.28 (Jun 15, 2011)
- Improve the form validation error check JENKINS-9625
- Supported security level of the comment JENKINS-1489
Version 1.27 (Feb 27, 2011)
- Updates for Jenkins
Version 1.26 (Jan 14, 2011)
- (JENKINS-2508) : JIRA plugin not updating JIRA when perforce plugin used.
Version 1.25
- (JENKINS-6758) : Failed to save system settings with JIRA Plugin.
Version 1.24
- (JENKINS-6462) : Version 1.355 of Hudson and Jira Plugin 1.21: Images in Jira comments are not showing up.
Version 1.23
- (JENKINS-6264, JENKINS-6282) fixed : IndexOutOfBoundsException when no issue pattern is configured (default pattern wasn't used)
- (JENKINS-6381) fixed : configured patterned wasn't used for changelog annotation. Default pattern was always used for that.
- improved default pattern to not match commit messages with dots in the number part (like 'projectname-1.2.3'). These messages are e.g. used by the Maven release plugin
Version 1.22
- (JENKINS-6043) : Issue pattern can be configurable
- (JENKINS-6225) : option to update jira issue whatever the build result is (even if failed)
Version 1.21
- (JENKINS-5989) : option to record scm changes in jira.
- (JENKINS-6007) : Added French localization.
Version 1.20
- Added Japanese localization (JENKINS-5788)
Version 1.19
- Fix: Prevent carrying forward invalid issue ids forever
Version 1.18
- Case insensitive matching of JIRA ids also in the 'recent changes' view (JENKINS-4132)
- fetch missing details for JIRA issues - i.e. completes issue title tooltip in 'recent changes' view (JENKINS-5252)
- prevent build FAILURE if JIRA site is not available (JENKINS-3046)
Version 1.17
- Fixed an
ArrayIndexOutOfBoundsException
when JIRA issues contain '$' in the name. - Support underscore in project names (JENKINS-4092)
- Support digits in project names (JENKINS-729)
- Case insensitive matching of JIRA ids (JENKINS-4132)
- Don't strip JIRA id from posted comment
- German translation
Version 1.15 (2008/08/22)
- Update JIRA if the build is UNSTABLE or better. Previously only updated if the build was stable.
- Include relevant SCM comment in the JIRA comment which should make JIRA ticket history more meaningful.
Version 1.13 (2008/08/05)
- Fixed a performance issue in a large enterprise deployment of JIRA (JENKINS-1703)
Version 1.12
- A typo in the commit message shouldn't break builds (JENKINS-1593)
- Postpone JIRA updates until a successful build is obtained (JENKINS-506)
Version 1.11
- Added more logging and debug flag to examine issues that people are reporting (report)
Version 1.10
- Wiki-style notation option wasn't persisted (JENKINS-977)
- Fixed a packaging problem (JENKINS-1127)
Version 1.9
- Fixed NPE when failed to talk to JIRA (JENKINS-1097)
Version 1.8
- Be more graceful in dealing with URLs (JENKINS-896)
- URLs need to be escaped (JENKINS-943)
Version 1.7
- Fixed NPE when username/password is not set (JENKINS-828)
Version 1.6
- Relaxed the JIRA project key regexp a little bit to allow numbers (JENKINS-729)
Version 1.5
- Issue hyperlinking is now smart enough not to be confused by strings that look like JIRA issue that actually aren't.
Version 1.4
- Fixed a bug that prevented tooltips for JIRA issues from being displayed JENKINS-694
Attachments:
JIRA Comments.jpg (image/jpeg)
Build Details.jpg (image/jpeg)
version_parameters.png (image/png)
mark_as_resolved.png (image/png)
move_issues.png (image/png)
release_notes.png (image/png)
release_notes_config.png (image/png)
example_annotated_changelog.png (image/png)
escaped_html_issue.png (image/png)
image2018-1-4 16:5:10.png (image/png)
image2018-1-4 16:8:19.png (image/png)
image2018-1-4 17:43:50.png (image/png)
image2019-5-3_17-40-25.png (image/png)
image2019-5-3_17-42-18.png (image/png)