Mercurial > prosody-hg
diff util/startup.lua @ 13988:260a6feebe5f
util.startup: Add metric bucket for zero DNS records
Otherwise hard to tell the difference between 0 and 1 :)
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Sat, 18 Oct 2025 00:53:43 +0200 |
| parents | ccbc4a46f42d |
| children | a8aa17293d22 |
line wrap: on
line diff
--- a/util/startup.lua Thu Oct 16 18:29:03 2025 +0100 +++ b/util/startup.lua Sat Oct 18 00:53:43 2025 +0200 @@ -450,7 +450,7 @@ buckets = { 1 / 1024; 1 / 256; 1 / 64; 1 / 16; 1 / 4; 1; 4 }; }); local c = statsmanager.metric("histogram", "prosody_dns_response", "records", "DNS response records", { "qclass"; "qtype" }, { - buckets = { 1; 2; 4; 8; 16 } }) + buckets = { 0; 1; 2; 4; 8; 16 } }) local function m_times(qclass, qtype) return timed(m:with_labels(qclass, qtype)); end local function m_counts(qclass, qtype, num) return c:with_labels(qclass, qtype):sample(num); end adns.instrument(m_times, m_counts);
