bin/riemann-babbler in riemann-babbler-0.4.4 vs bin/riemann-babbler in riemann-babbler-0.4.5
- old
+ new
@@ -37,9 +37,26 @@
config_default = YAML.load_file( File.expand_path('../../config.yml', __FILE__) )
config = config_default.deep_merge( config_file )
configatron.configure_from_hash config
+# set logger lvl
+case configatron.logger.level
+ when "INFO"
+ logger.level = Logger::INFO
+ when "WARN"
+ logger.level = Logger::WARN
+ when "ERROR"
+ logger.level = Logger::ERROR
+ when "FATAL"
+ logger.level = Logger::FATAL
+ when "UNKNOWN"
+ logger.level = Logger::UNKNOWN
+ else
+ logger.level = Logger::DEBUG
+end
+
+
# get plugins
plugins = []
default_plugins_dir = File.expand_path('../../lib/riemann/babbler/plugins/', __FILE__)
Dir.glob( default_plugins_dir + "/*.rb" ) do |file|
plugins << file