Skip to content

Conversation

@surinkim
Copy link

This pull request fixes a bug where Alertmanager would create a duplicate Jira issue if the existing issue's resolution field was null (for example, when the issue was still "To Do" or "In Progress").

Previously, the search query only checked for resolution != "Won't Do", so issues with null resolution were not properly matched, causing Alertmanager to incorrectly create a new issue.

This fix updates the JQL condition to also check resolution is EMPTY or resolution != "Won't Do", ensuring that open issues are correctly found and reused.

Changes

  • Modified the Jira JQL query condition to correctly handle issues with null resolution.
  • Added corresponding unit tests to verify this behavior.

Screenshots

Before

  • Search JQL: resolution != "Won't Do" only
  • Behavior: create new issue even if there is an open issue

Before Fix

After

  • Search JQL: resolution is EMPTY or resolution != "Won't Do"
  • Behavior: update existing issue properly without creating a duplicate

After Fix


Fixes #4295.

@cicadadevops
Copy link

Could you please share the Jira integration and Alertmanager configuration?

@surinkim
Copy link
Author

Here is the Jira integration and Alertmanager configuration I used for testing:


Jira Environment


Alertmanager Configuration

@cicadadevops
Copy link

Has anyone tried integrating Alertmanager with Jira Data Center?
I’m using Jira Data Center version 10.3.6, but unfortunately, I haven’t been able to get it to work correctly.
Sometimes it fails to reopen existing tickets, and sometimes it doesn’t create new ones at all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Native Jira Integration: JQL Query Excludes Unresolved Issues When Using wont_fix_resolution

2 participants