influxdata / influxdata/kapacitor

OpsGenie alerts description is not the AlertNode Details

Open
#1,130 7 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
2.4k
Forks
479
Avg merge
4d 16h
Merged PRs (30d)
4

Description

Using the current version of the OpsGenie service for alerting, I assumed that the Description field within the alert created on OpsGenie would be the Details property of the alert node (event.State.Details), but it is in fact hardcoded to event.Data.Result, which is the unmodifiable result data of the InfluxQL query which resulted in the alert's creation.

You can see it there: https://github.com/influxdata/kapacitor/blob/master/services/opsgenie/service.go#L224

It seems more intuitive to me as well as more inline with the other alerting services to link the description of the alert in OpsGenie, which accepts HTML code, to the customizable Details property. A rough implementation can be found here: https://github.com/fdhex/kapacitor/commit/95d60595dea8c524d451ed9f43df6271a57e9b4e

I would propose this implementation to be the new default, but I think it would be important to keep the previous functionality as an optional choice. Pinging the original author of the service @ericiles for opinion here.

Contributor guide

Open the contributing guide

Research direction

Start in services/opsgenie/service.go at line 224 and compare the current use of event.Data.Result with the customizable event.State.Details property. Review the linked rough implementation and the issue discussion, then determine how to make Details the default while preserving the previous behavior as an option. Done means the OpsGenie description follows the selected alert property.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
observability-sre
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.