Serve the delivery duration histogram from boot (closes #267) #427

Merged
clawbot merged 1 commits from issue-267-duration-from-boot into next 2026-10-02 12:45:06 +02:00
Collaborator

webhooker_delivery_duration_seconds was missing from /metrics until the first delivery, while every other delivery series is created at zero when the collectors are registered. On a dashboard or in an alert rule an absent series looks the same as a broken exporter.

initSeries now creates the histogram for the same four target types as the other delivery series, so an instance that has delivered nothing serves it with a zero count and sum. Like the other per-target-type delivery series it has no unknown series from boot; only the two queue-depth gauges do.

The registration test now lists the histogram with the other series, and a new route test scrapes /metrics on a freshly built instance and finds webhooker_delivery_duration_seconds_count at zero for each target type.

Judgement call: the issue allowed closing it instead if a histogram with no observations was judged meaningless; it is materialised, because a zero count can be told apart from an absent series, which is what the issue asks for.

Closes #267

Model: opus-5-5

`webhooker_delivery_duration_seconds` was missing from `/metrics` until the first delivery, while every other delivery series is created at zero when the collectors are registered. On a dashboard or in an alert rule an absent series looks the same as a broken exporter. `initSeries` now creates the histogram for the same four target types as the other delivery series, so an instance that has delivered nothing serves it with a zero count and sum. Like the other per-target-type delivery series it has no `unknown` series from boot; only the two queue-depth gauges do. The registration test now lists the histogram with the other series, and a new route test scrapes `/metrics` on a freshly built instance and finds `webhooker_delivery_duration_seconds_count` at zero for each target type. Judgement call: the issue allowed closing it instead if a histogram with no observations was judged meaningless; it is materialised, because a zero count can be told apart from an absent series, which is what the issue asks for. Closes https://git.eeqj.de/sneak/webhooker/issues/267 Model: opus-5-5
clawbot added the needs-review label 2026-10-02 10:50:11 +02:00
clawbot self-assigned this 2026-10-02 10:50:11 +02:00
clawbot added 1 commit 2026-10-02 10:50:12 +02:00
webhooker_delivery_duration_seconds was absent from /metrics until the first delivery, while every other delivery series is materialised at zero when the collectors are registered. initSeries now materialises the histogram too, for the same four target types, so a scrape of an instance that has delivered nothing shows it with a zero count and sum. The registration test lists it with the other series, and a new route test scrapes /metrics on a freshly built instance and finds it for every target type.

Model: opus-5-5
Author
Collaborator

Review passed: the delivery duration histogram is served from boot for the four target types, and the new tests pin it.

Model: opus-5-5

Review passed: the delivery duration histogram is served from boot for the four target types, and the new tests pin it. Model: opus-5-5
Author
Collaborator

Re-gate passed on current next.

Model: opus-5-5

Re-gate passed on current next. Model: opus-5-5
clawbot merged commit b14b27b78b into next 2026-10-02 12:45:06 +02:00
clawbot deleted branch issue-267-duration-from-boot 2026-10-02 12:45:06 +02:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/webhooker#427