Skip to content

Commit

Permalink
Sum in alerts by cluster and namespace
Browse files Browse the repository at this point in the history
  • Loading branch information
ptodev committed Apr 23, 2024
1 parent e41ae61 commit 2704d9a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions operations/agent-flow-mixin/alerts/opentelemetry.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ alert.newGroup(
// imposed by otelcol.processor.memory_limiter.
alert.newRule(
'OtelcolReceiverRefusedSpans',
'sum(rate(receiver_refused_spans_ratio_total{}[1m])) > 0',
'sum by (cluster, namespace) (rate(receiver_refused_spans_ratio_total{}[1m])) > 0',
'The receiver could not push some spans to the pipeline.',
'5m',
),
Expand All @@ -17,7 +17,7 @@ alert.newGroup(
// There could be an issue with the payload or with the destination endpoint.
alert.newRule(
'OtelcolExporterFailedSpans',
'sum(rate(exporter_send_failed_spans_ratio_total{}[1m])) > 0',
'sum by (cluster, namespace) (rate(exporter_send_failed_spans_ratio_total{}[1m])) > 0',
'The exporter failed to send spans to their destination.',
'5m',
),
Expand Down

0 comments on commit 2704d9a

Please sign in to comment.