From 5564e9cacda90ff9154e9091ce7f960c814103d7 Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Wed, 6 Jun 2018 14:53:41 +0200 Subject: [PATCH] dnsdist: Limit QPS and latency to two decimals in the web view --- pdns/dnsdistdist/html/local.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pdns/dnsdistdist/html/local.js b/pdns/dnsdistdist/html/local.js index 26618447b5..641a2797b4 100644 --- a/pdns/dnsdistdist/html/local.js +++ b/pdns/dnsdistdist/html/local.js @@ -159,7 +159,7 @@ $(document).ready(function() { $("#cpu").text(cpu.toFixed(2)); var qps=1.0*data["queries"]-1.0*gdata["queries"]; - $("#qps").text(qps); + $("#qps").text(qps.toFixed(2)); $("#server-policy").text(data["server-policy"]); var servfailps=1.0*data["servfail-responses"]-1.0*gdata["servfail-responses"]; @@ -194,7 +194,7 @@ $(document).ready(function() { var bouw=''; $.each(data["servers"], function(a,b) { bouw = bouw + (""); - bouw = bouw + (""); + bouw = bouw + (""); bouw = bouw + (""); }); bouw = bouw + "
#NameAddressStatusLatencyQueriesDropsQPSOutWeightOrderPools
"+b["id"]+""+b["name"]+""+b["address"]+""+b["state"]+""+b["latency"]+""+b["queries"]+""+b["reuseds"]+""+b["qps"]+""+b["outstanding"]+""+(b["latency"]).toFixed(2)+""+b["queries"]+""+b["reuseds"]+""+(b["qps"]).toFixed(2)+""+b["outstanding"]+""+b["weight"]+""+b["order"]+""+b["pools"]+"
"; -- 2.47.2