It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Duplicate tickets for same alerts are created in Jira Edited

I have recently integrated opsgenie to Jira integration to get the tickets for alerts in opsgenie. But the issue is there is a lot of noise since there are same alerts again and again and similarly tickets are generated for the same alerts. There should be one ticket for the same alerts and not duplicates. Any idea on how can that be done in opsgenie or Jira side?

1 answer

The key to this is you want to "de-duplicate" the alert in opsgenie, so that only one opsgenie alert is created.

opsgenie uses the "alias" field to determine if two alerts are for the same event. If they have the same alias, and there is an open alerts for the alias, a new one will not be created.

So what you want to do is see what the alias field is set to currently, and modify it to allow it to be the same for the same alerts.

Exactly how to do this is very dependent on the opsgenie integration and how the alerts are being created, so I cant give you specifics.

However, Opsgenie support is VERY helpful at helping you to create the right rules. I'd suggest reaching out to them (even via the chatbox on thier site) and asking for thier assistance in building the alias.

Hey @Andrew_Laden

Thanks for the reply. The issue is that I am talking about the Jira side. I understand about the Alias concept that opsgenie uses. The use case is that if you get an alert a ticket is created in opsgenie. Now after some time the alert gets closed and then opens again after lets say X hours. The ticket on the Jira for that alert is already there and it again creates a new one since its a new alert right. 

So I wanted to see that if an issue exists in Jira -- for an alert lets say ABC no matter how many times the alert ABC flaps -- there should be no duplicate tickets in Jira for the alert ABC if it comes lets say 4 times a day.

I hope I made it clear. Thank You !!

Thats a little harder. The general model is 1 jira issue to 1 opsgenie alert. If you want a model of many opsgenie alerts to 1 jira issue, you are going to have to do that yourself.

Are you using OEC to generate the jira issues from opsgenie? or are you using the native integration. If you are using OEC, you could theoretically write some validation code in that could search jira for an open issue matching your parameters and if found change to a comment operation instead of a create, but its going to take some work to get that right.

Yeah, that's what I thought as well. I am currently using native integration. I guess I will have to switch to OEC and write a script to call Jira API and search for the issues and if that exists then there is no need to make another ticket.

What are your thoughts on https://confluence.atlassian.com/adminjiraserver073/creating-issues-and-comments-from-email-861253784.html?_ga=2.202354585.924284190.1583141218-1364091263.1530101294

Do you think this could be useful?

Not really. I suppose you are thinking of having the email from opsgenie create the ticket instead of the integration? 

You would actually make your situation worse. When an email comes in, jira tries to figure out if it should comment on an existing ticket, or open a new one. There are a few ways it tries. 

1: Looks for an jira issue key in the subject of the email

2: looks for "in-reply-to" or "in-response-to" headers, and tries to match up to a previous email.

Neither of these will match, so every mail from opsgenie will create a new issue. 

The built in jira email handler isnt very configurable.

If you have a add on email handlers (JEMH for example) you could write some custom handling to try to match a mail up to an existing issue. Would probably be harder them the OEC solution.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Opsgenie

A deep dive on Routing Rules

  Hi there! Folks new to Opsgenie sometimes can get a bit perplexed when setting up their Routing Rules and Escalation Policies. Especially if they’re used to using an excel spreadsheet for sc...

183 views 0 2
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you