Skip to content

Commit

Permalink
feat: promethues add record rule (#127)
Browse files Browse the repository at this point in the history
Add http_request_duration record rule that captures the aggregated rates. This way, we only write the aggregated rule once and reuse it for different quantiles i.e.
  • Loading branch information
saidsef authored Nov 17, 2024
1 parent 0043206 commit 63d8d17
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions deployment/prometheus/cm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,18 @@ metadata:
data:
alerting_rules.yml: |
groups:
- name: http_request_duration
rules:
- record: job:request_duration_seconds:rate
expr: |
sum(rate(hubble_http_request_duration_seconds_bucket{
cluster=~"${cluster}",
destination_namespace=~"${destination_namespace}",
destination_workload=~"${destination_workload}",
reporter="${reporter}",
source_namespace=~"${source_namespace}",
source_workload=~"${source_workload}"
}[5m])) by (cluster, destination_namespace, destination_workload, le)
- name: Memory
rules:
- alert: ContainerUsedMemoryPercent
Expand Down

0 comments on commit 63d8d17

Please sign in to comment.