fix(monitoring): resolve 5XX alert false positives from Stackdriver no-data#9567
Conversation
Stackdriver queries filtered by response_code_class=500 return no data when there are zero 5XX errors. With noDataState=Alerting, this causes a false-positive alert firing with sentinel value -1. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Same Stackdriver no-data false-positive as backend 5XX rule. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Same Stackdriver no-data false-positive as backend 5XX rule. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
@beastoin No issues found. The diff is limited to the three Stackdriver-backed 5XX rules, and Please keep the deploy-side Grafana resolution check from the PR test plan. by AI for @beastoin |
|
Test results:
|
kodjima33
left a comment
There was a problem hiding this comment.
Backend bug fix — root cause stated, scoped, CI green. Merging.
Summary
noDataStatefrom"Alerting"to"OK"for backend, backend-integration, and backend-sync 5XX rulesRoot Cause
Stackdriver queries filtered by
response_code_class = "500"return no data when there are zero 5XX errors. WithnoDataState: "Alerting", Grafana treats no-data as an alert condition and fires with sentinel value-1. This is the firing alert mon reported: "Backend - 5XX error rate is high" with value -1.Prometheus-based 5XX rules are not affected because they use
or vector(0)to return 0 instead of no-data. Stackdriver queries cannot useor vector(0).Changes
backend.jsoncew4jcnpa68sgabackend-integration.jsoneew96o25qztvkfbackend-sync.jsoncew97uqu791q8aEach:
noDataState: "Alerting"→noDataState: "OK"Test plan
python3 -m json.toolon all 3 files)noDataState: "Alerting"in the 3 changed files🤖 Generated with Claude Code