Refactor JIRABuildNotifier to a more common RunListener implementations
Description
Environment
None
is related to
Activity
Show:
Fixed
Pinned fields
Click on the next to a field label to start pinning.
Created July 14, 2016 at 10:15 AM
Updated September 27, 2016 at 12:55 PM
Resolved September 16, 2016 at 6:08 PM
Zoom
Currently the JIRA plugin will register a
JIRABuildNotifier
in Jenkins for every Job. But this notifier doesn't play nicely with jobs that themselves have sub-jobs like Pipeline and Folder jobs.If we refactor the job specific
JIRABuildNotifier
to an Instance genericRunListener
then it becomes easier to maintain the notification feature implemented by theJIRABuildNotifier
.This
RunListener
should simplyPUT
the Job URL and Build number to an endpoint in JIRA, so that JIRA can then handle the synchronization like how it does it now.All linked JIRA instances should be managed Instance wide and not per Job.
This will also effect the
JIRAChangeLogAnnotator
since this uses theJIRABuildNotifier
to lookup the JIRA Issue Keys. It should be refactored to use the same linked JIRA instances list and use theIssueKeyExtractor
to locate issue keys instead of looking them up using JIRA.