webhooker_delivery_duration_seconds is absent from a scrape until the first delivery occurs #267
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Confirmed by execution during the review of #264: on a freshly started instance that has delivered nothing,
webhooker_delivery_duration_secondsdoes not appear in/metricsat all (grep count 0).initSeriesininternal/metrics/metrics.gomaterialises every delivery counter and gauge at zero, but notdeliveryDuration. The other eightwebhooker_*delivery series are present from boot; this one is not.Why it matters rather than being merely tidy: #209 exists so an operator can alert on delivery health. On a dashboard or in an alert rule, an absent series is indistinguishable from a broken exporter or a misspelled metric name — the operator cannot tell "nothing has been delivered yet" from "my monitoring is wrong". Materialising it at zero removes that ambiguity, which is the same reasoning that put the other eight in
initSeries.Narrow, and only observable before the first delivery, which is why it is not milestoned.
Definition of done:
deliveryDurationis materialised ininitSeriesfor the same target-type label set the other delivery series use, so it appears from boot.webhooker_delivery_duration_secondsis present in a scrape from an instance that has delivered nothing.