From a0f4979d1138c5e677f985a210a7c6228f120007 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miha=20Ple=C5=A1ko?= Date: Mon, 13 Nov 2017 15:36:47 +0100 Subject: [PATCH] Introduce $nuage_log that logs into log/nuage.log MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit With this commit we introduce yet another global logger that is to be used by nuage provider. We're having quite some logs there and it's better to log them into its own file. Signed-off-by: Miha Pleško --- .rubocop_local.yml | 1 + config/settings.yml | 1 + lib/vmdb/loggers.rb | 2 ++ 3 files changed, 4 insertions(+) diff --git a/.rubocop_local.yml b/.rubocop_local.yml index e55f18c21ba..d386c2b9446 100644 --- a/.rubocop_local.yml +++ b/.rubocop_local.yml @@ -25,6 +25,7 @@ GlobalVars: - $vcloud_log - $vim_log - $websocket_log + - $nuage_log Rails/Exit: Exclude: - lib/workers/bin/* diff --git a/config/settings.yml b/config/settings.yml index b9082e6ec98..d2f1f504b28 100644 --- a/config/settings.yml +++ b/config/settings.yml @@ -881,6 +881,7 @@ :level_vim: warn :level_websocket: info :level_vcloud: info + :level_nuage: info :ntp: :server: - 0.pool.ntp.org diff --git a/lib/vmdb/loggers.rb b/lib/vmdb/loggers.rb index 4d540d922ea..f566a57b8cc 100644 --- a/lib/vmdb/loggers.rb +++ b/lib/vmdb/loggers.rb @@ -99,6 +99,7 @@ def self.apply_config(config) apply_config_value(config, $lenovo_log, :level_lenovo) apply_config_value(config, $websocket_log, :level_websocket) apply_config_value(config, $vcloud_log, :level_vcloud) + apply_config_value(config, $nuage_log, :level_nuage) end def self.create_loggers @@ -124,6 +125,7 @@ def self.create_loggers $websocket_log = create_multicast_logger(path_dir.join("websocket.log")) $miq_ae_logger = create_multicast_logger(path_dir.join("automation.log")) $vcloud_log = create_multicast_logger(path_dir.join("vcloud.log")) + $nuage_log = create_multicast_logger(path_dir.join("nuage.log")) configure_external_loggers end