mirror of
https://github.com/ntop/ntopng.git
synced 2026-04-30 07:59:35 +00:00
Refactors alerts and flow statuses in builtin and plugins
Implements #3811 Implements #3812 Refactors builtin alerts Refactors builtin flow statuses
This commit is contained in:
parent
1c76667b21
commit
78b334e4eb
89 changed files with 680 additions and 39 deletions
|
|
@ -0,0 +1,28 @@
|
|||
--
|
||||
-- (C) 2019-20 - ntop.org
|
||||
--
|
||||
|
||||
local alert_keys = require "alert_keys"
|
||||
|
||||
package.path = dirs.installdir .. "/scripts/lua/modules/?.lua;" .. package.path
|
||||
local format_utils = require "format_utils"
|
||||
|
||||
local function slowPeriodicActivityFormatter(ifid, alert, info)
|
||||
local max_duration
|
||||
|
||||
max_duration = format_utils.secondsToTime(info.max_duration_ms / 1000)
|
||||
|
||||
return(i18n("alert_messages.slow_periodic_activity", {
|
||||
script = info.ps_name,
|
||||
max_duration = max_duration,
|
||||
}))
|
||||
end
|
||||
|
||||
-- #######################################################
|
||||
|
||||
return {
|
||||
alert_key = alert_keys.ntopng.alert_slow_periodic_activity,
|
||||
i18n_title = "alerts_dashboard.slow_periodic_activity",
|
||||
i18n_description = slowPeriodicActivityFormatter,
|
||||
icon = "fas fa-undo",
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue