Repository navigation
v0.28.51
Changes
test: stabilize Prometheus metrics duration assertions (#4360)
Why
CI runs sometimes fail while checking Prometheus latency metrics. The
scrape is missing the expected duration sum of 0.015 seconds, for a host
or for a backend zone.
Those sums are measured with the process clock. Work between the start
instant and the observation still consumes wall time, so the exported
sum lands past 0.015 seconds and the expected line is absent from the
scrape.
What changed
Each metrics case now runs inside synctest.Test. In that bubble the
clock advances only when every goroutine is blocked, so the measured
interval stays at the 15 milliseconds the expected sum encodes. The test
also closes the scrape body, reports a read failure, and returns when
the status code is wrong.
Testing
Go test ./metrics/... passed for both metrics packages.
Fixes #3072
Multiarch Docker image
Multiarch Docker image is available in GitHub's docker registry:
docker run -it ghcr.io/zalando/skipper:v0.28.51 skipper --help