Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Yaroslav Dynnikov <[email protected]>
  • Loading branch information
yngvar-antonsson and rosik authored Jul 30, 2021
1 parent 6e73349 commit 0af589d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions metrics/default_metrics/tarantool/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,13 @@ local default_metrics = {
}

local function delete_collectors(list)
if list == nil then
return
end
for _, collector in pairs(list) do
metrics.registry:unregister(collector)
end
table.clear(list)
end

local function enable(include, exclude)
Expand Down
2 changes: 1 addition & 1 deletion metrics/default_metrics/tarantool/memory.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ local function update_memory_metrics()
local i = box.info.memory()
for k, v in pairs(i) do
local metric_name = 'info_memory_' .. k
collectors_list[metric_name] = utils.set_gauge(metric_name, 'Memory' .. k, v)
collectors_list[metric_name] = utils.set_gauge(metric_name, 'Memory ' .. k, v)
end
end
end
Expand Down

0 comments on commit 0af589d

Please sign in to comment.