Removes arbitrary threshold in top talkers

This commit is contained in:
Simone Mainardi 2017-12-01 19:06:59 +01:00
parent d35dda0fa4
commit 6e5840cd73

View file

@ -9,7 +9,6 @@ local json = require "dkjson"
local top_talkers_utils = {}
top_talkers_utils.MAX_NUM_ENTRIES = 10
top_talkers_utils.THRESHOLD_LOW = .05
local vlan_totals = {}
local asname_cache = {}
@ -54,13 +53,6 @@ local function sortRes(res)
end
end
for what_val_k, delta in pairs(direction_val) do
if delta / total < top_talkers_utils.THRESHOLD_LOW then
if delta > 0 then other = other + delta end
direction_val[what_val_k] = nil
end
end
if other > 0 then
direction_val["Other"] = other
end