From: Otto Moerbeek Date: Tue, 1 Feb 2022 15:36:30 +0000 (+0100) Subject: rename metric name, promtool says: X-Git-Tag: auth-4.7.0-alpha1~23^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=81b22ab6ba17f3e1c2bc03c3a46600b5594a8ee1;p=thirdparty%2Fpdns.git rename metric name, promtool says: pdns_recursor_non_resolving_ns_entries metric names should not contain abbreviated units --- diff --git a/pdns/rec-snmp.cc b/pdns/rec-snmp.cc index f1d33799f2..e312135dc7 100644 --- a/pdns/rec-snmp.cc +++ b/pdns/rec-snmp.cc @@ -145,7 +145,7 @@ static const oid udp6InCsumErrorsOID[] = {RECURSOR_STATS_OID, 123}; #endif /* __linux__ */ static const oid sourceDisallowedNotifyOID[] = {RECURSOR_STATS_OID, 124}; static const oid zoneDisallowedNotifyOID[] = {RECURSOR_STATS_OID, 125}; -static const oid nonResolvingNSEntriesOID[] = {RECURSOR_STATS_OID, 126}; +static const oid nonResolvingNameserverEntriesOID[] = {RECURSOR_STATS_OID, 126}; static std::unordered_map s_statsMap; @@ -380,6 +380,6 @@ RecursorSNMPAgent::RecursorSNMPAgent(const std::string& name, const std::string& registerCounter64Stat("almost-expired-pushed", almostExpiredPushed, OID_LENGTH(almostExpiredPushed)); registerCounter64Stat("almost-expired-run", almostExpiredRun, OID_LENGTH(almostExpiredRun)); registerCounter64Stat("almost-expired-exceptions", almostExpiredExceptions, OID_LENGTH(almostExpiredExceptions)); - registerCounter64Stat("non-resolving-ns-entries", nonResolvingNSEntriesOID, OID_LENGTH(nonResolvingNSEntriesOID)); + registerCounter64Stat("non-resolving-nameserver-entries", nonResolvingNameserverEntriesOID, OID_LENGTH(nonResolvingNameserverEntriesOID)); #endif /* HAVE_NET_SNMP */ } diff --git a/pdns/rec_channel_rec.cc b/pdns/rec_channel_rec.cc index 3a56a59f7d..1010369cf0 100644 --- a/pdns/rec_channel_rec.cc +++ b/pdns/rec_channel_rec.cc @@ -1242,7 +1242,7 @@ static void registerAllStats1() addGetStat("nsspeeds-entries", getNsSpeedsSize); addGetStat("failed-host-entries", SyncRes::getFailedServersSize); - addGetStat("non-resolving-ns-entries", SyncRes::getNonResolvingNSSize); + addGetStat("non-resolving-nameserver-entries", SyncRes::getNonResolvingNSSize); addGetStat("concurrent-queries", getConcurrentQueries); addGetStat("security-status", &g_security_status); diff --git a/pdns/recursordist/RECURSOR-MIB.txt b/pdns/recursordist/RECURSOR-MIB.txt index 2992e94710..dc21ae2224 100644 --- a/pdns/recursordist/RECURSOR-MIB.txt +++ b/pdns/recursordist/RECURSOR-MIB.txt @@ -1054,7 +1054,7 @@ zoneDisallowedNotify OBJECT-TYPE "Number of NOTIFY operations not allowed by allow-notify-for" ::= { stats 125 } -nonResolvingNSEntries OBJECT-TYPE +nonResolvingNameserverEntries OBJECT-TYPE SYNTAX CounterBasedGauge64 MAX-ACCESS read-only STATUS current diff --git a/pdns/recursordist/docs/metrics.rst b/pdns/recursordist/docs/metrics.rst index c59fba5923..965aa955fd 100644 --- a/pdns/recursordist/docs/metrics.rst +++ b/pdns/recursordist/docs/metrics.rst @@ -546,7 +546,7 @@ noerror-answers ^^^^^^^^^^^^^^^ counts the number of times it answered NOERROR since starting -non-resolving-ns-entries +non-resolving-nameserver-entries ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ number of entries in the non-resolving NS name cache diff --git a/pdns/ws-recursor.cc b/pdns/ws-recursor.cc index 3c31fc90af..8a01b41eb3 100644 --- a/pdns/ws-recursor.cc +++ b/pdns/ws-recursor.cc @@ -692,7 +692,7 @@ const std::map MetricDefinitionStorage::d_metrics {"failed-host-entries", MetricDefinition(PrometheusMetricType::gauge, "Number of entries in the failed NS cache")}, - {"non-resolving-ns-entries", + {"non-resolving-nameserver-entries", MetricDefinition(PrometheusMetricType::gauge, "Number of entries in the non-resolving NS name cache")}, {"ignored-packets",