mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-06 03:45:26 +00:00
Removed non standard connotations (#6878)
This commit is contained in:
parent
cb1d74ee3a
commit
52c316d214
11 changed files with 23 additions and 23 deletions
|
|
@ -411,7 +411,7 @@ function loadDefinition(def_script, mod_fname, script_path)
|
|||
return(false)
|
||||
end
|
||||
|
||||
-- Sanity check: make sure the alert key is not redefined
|
||||
-- Coherence check: make sure the alert key is not redefined
|
||||
local alert_entity_id = alert_entity.entity_id
|
||||
|
||||
if alerts_by_id[alert_entity_id] and alerts_by_id[alert_entity_id][alert_key] then
|
||||
|
|
|
|||
|
|
@ -1135,7 +1135,7 @@ function alert_store:_prepare_count_by_severity_and_time_series(all_severities,
|
|||
local res = {}
|
||||
|
||||
if table.len(all_severities) == 0 then
|
||||
-- No series, add a dummy series for "no alerts"
|
||||
-- No series, add a placeholder series for "no alerts"
|
||||
local noalert_res = {}
|
||||
for slot = min_slot, max_slot + 1, time_slot_width do
|
||||
noalert_res[#noalert_res + 1] = {slot * 1000 --[[ In milliseconds --]], 0}
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ function code_editor.editor(plugin_file_path, plugin_path, referarl_script_page)
|
|||
plugin_file_url = string.gsub(plugin_file_path, "/plugins/", "/plugins-src/")
|
||||
end
|
||||
|
||||
-- Sanity check, never go outside the plugins directory
|
||||
-- Coherence check, never go outside the plugins directory
|
||||
if starts(plugin_path, "/plugins/") then
|
||||
plugin_path = os_utils.fixPath(string.format("%s/%s", dirs.scriptdir, plugin_path))
|
||||
else
|
||||
|
|
@ -138,4 +138,4 @@ end
|
|||
|
||||
-- #################################
|
||||
|
||||
return code_editor
|
||||
return code_editor
|
||||
|
|
|
|||
|
|
@ -1275,7 +1275,7 @@ function discover.discover2table(interface_name, recache)
|
|||
|
||||
-- This is an ARP entry
|
||||
if(discover.debug) then io.write("Attempting to resolve "..ip.."\n") end
|
||||
local sym = ntop.getResolvedName(ip) -- dummy resolution just to fill-up the cache
|
||||
local sym = ntop.getResolvedName(ip) -- placeholder resolution just to fill-up the cache
|
||||
|
||||
interface.mdnsQueueNameToResolve(ip)
|
||||
|
||||
|
|
|
|||
|
|
@ -161,9 +161,9 @@ end
|
|||
|
||||
-- #################################################################
|
||||
|
||||
-- @brief Sanity checks for the endpoint key
|
||||
-- @brief coherence checks for the endpoint key
|
||||
-- @param endpoint_key A string with the notification endpoint key
|
||||
-- @return true if the sanity checks are ok, false otherwise
|
||||
-- @return true if the coherence checks are ok, false otherwise
|
||||
local function check_endpoint_key(endpoint_key)
|
||||
if not endpoints.get_types()[endpoint_key] then
|
||||
return false, {status = "failed", error = {type = "endpoint_not_existing"}}
|
||||
|
|
@ -174,9 +174,9 @@ end
|
|||
|
||||
-- #################################################################
|
||||
|
||||
-- @brief Sanity checks for the endpoint configuration name
|
||||
-- @brief coherence checks for the endpoint configuration name
|
||||
-- @param endpoint_conf_name A string with the configuration name
|
||||
-- @return true if the sanity checks are ok, false otherwise
|
||||
-- @return true if the coherence checks are ok, false otherwise
|
||||
local function check_endpoint_conf_name(endpoint_conf_name)
|
||||
if not endpoint_conf_name or endpoint_conf_name == "" then
|
||||
return false, {status = "failed", error = {type = "invalid_endpoint_conf_name"}}
|
||||
|
|
@ -187,7 +187,7 @@ end
|
|||
|
||||
-- #################################################################
|
||||
|
||||
-- @brief Sanity checks for the endpoint configuration parameters
|
||||
-- @brief coherence checks for the endpoint configuration parameters
|
||||
-- @param endpoint_key A string with the notification endpoint key
|
||||
-- @param endpoint_params A table with endpoint configuration params that will be possibly sanitized
|
||||
-- @return false with a description of the error, or true, with a table containing sanitized configuration params.
|
||||
|
|
|
|||
|
|
@ -250,7 +250,7 @@ end
|
|||
|
||||
-- ##############################################
|
||||
|
||||
-- @brief Sanity checks for the endpoint configuration parameters
|
||||
-- @brief Coherence checks for the endpoint configuration parameters
|
||||
-- @param endpoint_key A string with the notification endpoint key
|
||||
-- @param recipient_params A table with endpoint recipient params that will be possibly sanitized
|
||||
-- @return false with a description of the error, or true, with a table containing sanitized configuration params.
|
||||
|
|
@ -538,7 +538,7 @@ function recipients.test_recipient(endpoint_id, recipient_params)
|
|||
|
||||
local safe_params = status["safe_params"]
|
||||
|
||||
-- Create dummy recipient
|
||||
-- Create test recipient
|
||||
local recipient = {
|
||||
endpoint_id = ec["endpoint_id"],
|
||||
endpoint_conf_name = ec["endpoint_conf_name"],
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ unittest:appendTest("REST API: hosts",
|
|||
end
|
||||
)
|
||||
|
||||
unittest:appendTest("Dummy test",
|
||||
unittest:appendTest("Test",
|
||||
function()
|
||||
unittest:assertEqual(1, 1, "Math is an opinion")
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1085,7 +1085,7 @@ function driver:export()
|
|||
|
||||
local parsed_ts_point = line_protocol_to_tags_and_metrics(ts_point)
|
||||
|
||||
-- No need to do sanity checks on the schema. This queue is 'private' and should
|
||||
-- No need to do coherence checks on the schema. This queue is 'private' and should
|
||||
-- only be written with valid data already checked.
|
||||
local schema = ts_utils.getSchema(parsed_ts_point["schema_name"])
|
||||
local timestamp = parsed_ts_point["timestamp"]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue