[prometheus-statsd-exporter] fix default liveness/readiness probe path (/health returns 404)#6982
Open
yuval-s-wiz wants to merge 1 commit into
Open
Conversation
…> /-/healthy) statsd_exporter serves /-/healthy and /-/ready, not /health, so the chart's default liveness/readiness probe (/health) returns HTTP 404 and pods fail their probes with default values (readiness never Ready; liveness restarts). This affects statsd_exporter >= v0.24.0, including this chart's appVersion (v0.28.0) and the upstream prom/statsd-exporter image. /health worked only incidentally up to v0.22, whose "/" handler was a catch-all returning 200 for any path; v0.24.0 (2023-06) adopted exporter-toolkit's landing page, which 404s any path != "/", silently breaking the probe. Point both probes at /-/healthy, the canonical lightweight endpoint, which also satisfies the original intent of prometheus-community#2305 (avoid probing heavy /metrics). Signed-off-by: yuval-s-wiz <252454512+yuval-s-wiz@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The chart's default
livenessProbe/readinessProbeusehttpGet.path: /health, butstatsd_exporterreturns HTTP 404 on/health. With the chart's default values the pod fails its probes — readiness never goes Ready, and liveness restarts the container.Reproduce
Root cause
/healthwas introduced in #2305 on the assumption that the server exposes it. It doesn't have a dedicated/healthroute — statsd_exporter serves/-/healthyand/-/ready(added in prometheus/statsd_exporter#339)./healthreturned 200 only incidentally up to statsd_exporter v0.22, whose/handler was a catch-all that returned 200 for any path. In v0.24.0 (2023-06-02) the exporter adopted exporter-toolkit'sweb.NewLandingPage, which404s any path!= "/"— silently breaking this probe for every statsd_exporter>= v0.24, including this chart'sappVersion: v0.28.0and the upstreamprom/statsd-exporterimage.Fix
Point both probes at
/-/healthy— the canonical lightweight health endpoint. This also satisfies the original intent of #2305 (avoid probing the heavy/metricsendpoint). Chart version bumped1.0.0→1.0.1.