From: Pavel Odintsov Date: Fri, 31 Aug 2018 15:04:59 +0000 (+0100) Subject: Do not replace dot in metric names. Use singular form for metric base name X-Git-Tag: dnsdist-1.3.3~128^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d37db88f5cd87bdea6405729c3707aa5bd4b1d11;p=thirdparty%2Fpdns.git Do not replace dot in metric names. Use singular form for metric base name --- diff --git a/pdns/dnsdist-web.cc b/pdns/dnsdist-web.cc index 7eaa482106..ca979a56cd 100644 --- a/pdns/dnsdist-web.cc +++ b/pdns/dnsdist-web.cc @@ -427,7 +427,7 @@ static void connectionThread(int sock, ComboAddress remote, string password, str } auto states = g_dstates.getLocal(); - const string statesbase = "dnsdist_servers_"; + const string statesbase = "dnsdist_server_"; for (const auto& state : *states) { string serverName; @@ -454,7 +454,6 @@ static void connectionThread(int sock, ComboAddress remote, string password, str continue; string frontName = front->local.toString() + ":" + std::to_string(front->local.getPort()); - boost::replace_all(frontName, ".", "_"); string proto = (front->udpFD >= 0 ? "udp" : "tcp"); output << "dnsdist_frontend_queries{frontend=\"" << frontName << "\",proto=\"" << proto @@ -466,7 +465,6 @@ static void connectionThread(int sock, ComboAddress remote, string password, str for (const auto& entry : *localPools) { string poolName = entry.first; - boost::replace_all(poolName, ".", "_"); if (poolName.empty()) { poolName = "_default_";