lib/onering/cli/reporter.rb in onering-client-0.0.88 vs lib/onering/cli/reporter.rb in onering-client-0.0.89

- old
+ new

@@ -30,16 +30,16 @@ }.compact) end def self.run(args) begin - Onering::Logger.debug("Gathering local data for report") + Onering::Logger.debug("Gathering local data for report", "Onering::CLI::Report") report = Onering::Reporter.report().stringify_keys() # pull report overrides from the config file Onering::Config.get('reporter.fields',{}).each do |key, value| - Onering::Logger.debug("Override value #{key} from config file") + Onering::Logger.debug("Override value #{key} from config file", "Onering::CLI::Report") if value.is_a?(Hash) value.coalesce(key, nil, '.').each do |k,v| v = nil if ['null', '', '-'].include?(v.to_s.strip.chomp) report = report.set(k, v) @@ -51,11 +51,11 @@ end # pull overrides from CLI arguments @opts[:fields].each do |field| key, value = field.split('=', 2) - Onering::Logger.debug("Override value #{key} from command line argument") + Onering::Logger.debug("Override value #{key} from command line argument", "Onering::CLI::Report") value = nil if ['null', '', '-'].include?(value.to_s.strip.chomp) report = report.set(key, value) end @@ -68,10 +68,10 @@ end end return report rescue Timeout::Error - Onering::Logger.fatal!("Report took too long to generate, exiting...") + Onering::Logger.fatal!("Report took too long to generate, exiting...", "Onering::CLI::Report") end end end end end \ No newline at end of file