Class: Madvertise::Logging::ImprovedLogger::Formatter

Inherits:
Object
  • Object
show all
Defined in:
lib/madvertise/logging/improved_logger.rb

Overview

The Formatter class is responsible for formatting log messages. The default format is:

YYYY:MM:DD HH:MM:SS.MS daemon_name(pid) level: message

Constant Summary collapse

RUBY2SYSLOG =
{
  :debug => 7,
  :info => 6,
  :warn => 4,
  :error => 3,
  :fatal => 2,
  :unknown => 3,
}

Class Attribute Summary collapse

Class Attribute Details

.formatObject

Format string for log messages.



366
367
368
# File 'lib/madvertise/logging/improved_logger.rb', line 366

def format
  @format
end

.log4j_formatObject

Returns the value of attribute log4j_format.



367
368
369
# File 'lib/madvertise/logging/improved_logger.rb', line 367

def log4j_format
  @log4j_format
end

.time_formatObject

Format string for timestamps in log messages.



370
371
372
# File 'lib/madvertise/logging/improved_logger.rb', line 370

def time_format
  @time_format
end