[Observability] [Alerts] Recovered alert notifications can have wrongly mapped group values #213547
Labels
bug
Fixes for quality problems that affect the customer experience
Team:obs-ux-management
Observability Management User Experience Team
When group by fields of the rule are modified, the recovered alert notifications that use
context.group
orcontext.groupByKeys
can have wrongly mapped group values.Example scenario
host.name
andcontainer.id
and alert action message usescontext.group
orcontext.groupByKeys
depending on the rulecontext.group
:"group":[{"field":"host.name","value":"host-0"},{"field":"container.id","value":"container-0"}]
context.groupByKeys
:{"host":{"name":"host-0"},"container":{"id":"container-0"}}
container.name
andhost.name
context.group
:"group":[{"field":"container.name","value":"host-0"},{"field":"host.name","value":"container-0"}]
context.groupByKeys
:{"container":{"name":"host-0"},"host":{"name":"container-0"}}
This is due to relying on rule parameters to generate group context for recovered alerts as at this point rule parameters have changed which don't match with recovered alert Id anymore. Instead we should use alert document to extract rule parameters with either
kibana.alert.rule.parameters.groupBy
orkibana.alert.group.field
.Rules where this issue can happen
The text was updated successfully, but these errors were encountered: