You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I am using label filtering in a Teams sink. I've noticed that if I create a list of labels in the include attribute, where the labels name are the same, just the first label value is taken and the second is ignored.
To Reproduce
On Prometheus, I have a metric containing a label workflow_name. Let's call that one workflow_count{workflow_name}. This is used on an alert called workflowFailure. Having these elements, I have defined the following customPlaybook:
- name: "custom_playbook"
triggers:
- on_prometheus_alert:
alert_name: workflowFailure
actions:
- create_finding:
title: 'test $label.alertname'
aggregation_key: workflowFailure
severity: MEDIUM
description: |
This is a test of severity Medium
This is the scope section I am using in the Teams sink:
If my understanding is correct, the sink will be used when the workflow_name label is either monitoring-wf-1 OR monitoring-wf-2. If the cluster fires 2 alerts, one for monitoring-wf-1 and one for monitoring-wf-2, I would expect to get two different notifications, one for each workflow. However, I only get notified for monitoring-wf-1. If I switch the order of the labels as follows, I get notified for monitoring-wf-2 only instead. My feeling is that if the label key is duplicated (e.g, workflow_name), Robusta will take the first one it finds:
Describe the bug
I am using label filtering in a Teams sink. I've noticed that if I create a list of labels in the
include
attribute, where the labels name are the same, just the first label value is taken and the second is ignored.To Reproduce
On Prometheus, I have a metric containing a label
workflow_name
. Let's call that oneworkflow_count{workflow_name}
. This is used on an alert calledworkflowFailure
. Having these elements, I have defined the followingcustomPlaybook
:This is the
scope
section I am using in the Teams sink:If my understanding is correct, the sink will be used when the
workflow_name
label is eithermonitoring-wf-1
ORmonitoring-wf-2
. If the cluster fires 2 alerts, one formonitoring-wf-1
and one formonitoring-wf-2
, I would expect to get two different notifications, one for each workflow. However, I only get notified formonitoring-wf-1
. If I switch the order of the labels as follows, I get notified formonitoring-wf-2
only instead. My feeling is that if the label key is duplicated (e.g,workflow_name
), Robusta will take the first one it finds:Expected behavior
I should receive two different notifications.
The text was updated successfully, but these errors were encountered: