Class: Gitlab::MultiDestinationLogger
- Inherits:
-
Logger
- Object
- Logger
- Gitlab::MultiDestinationLogger
- Defined in:
- lib/gitlab/multi_destination_logger.rb
Direct Known Subclasses
Class Method Summary collapse
- .debug(message) ⇒ Object
- .error(message) ⇒ Object
- .file_name ⇒ Object
- .file_name_noext ⇒ Object
- .full_log_path ⇒ Object
- .info(message) ⇒ Object
- .loggers ⇒ Object
- .primary_logger ⇒ Object
- .read_latest ⇒ Object
- .warn(message) ⇒ Object
Instance Method Summary collapse
Class Method Details
.debug(message) ⇒ Object
9 10 11 |
# File 'lib/gitlab/multi_destination_logger.rb', line 9 def self.debug() loggers.each { |logger| logger.build.debug() } end |
.error(message) ⇒ Object
13 14 15 |
# File 'lib/gitlab/multi_destination_logger.rb', line 13 def self.error() loggers.each { |logger| logger.build.error() } end |
.file_name ⇒ Object
29 30 31 |
# File 'lib/gitlab/multi_destination_logger.rb', line 29 def self.file_name primary_logger.file_name end |
.file_name_noext ⇒ Object
37 38 39 |
# File 'lib/gitlab/multi_destination_logger.rb', line 37 def self.file_name_noext primary_logger.file_name_noext end |
.full_log_path ⇒ Object
33 34 35 |
# File 'lib/gitlab/multi_destination_logger.rb', line 33 def self.full_log_path primary_logger.full_log_path end |
.info(message) ⇒ Object
21 22 23 |
# File 'lib/gitlab/multi_destination_logger.rb', line 21 def self.info() loggers.each { |logger| logger.build.info() } end |
.loggers ⇒ Object
41 42 43 |
# File 'lib/gitlab/multi_destination_logger.rb', line 41 def self.loggers raise NotImplementedError end |
.primary_logger ⇒ Object
45 46 47 |
# File 'lib/gitlab/multi_destination_logger.rb', line 45 def self.primary_logger raise NotImplementedError end |
.read_latest ⇒ Object
25 26 27 |
# File 'lib/gitlab/multi_destination_logger.rb', line 25 def self.read_latest primary_logger.read_latest end |
.warn(message) ⇒ Object
17 18 19 |
# File 'lib/gitlab/multi_destination_logger.rb', line 17 def self.warn() loggers.each { |logger| logger.build.warn() } end |
Instance Method Details
#close ⇒ Object
5 6 7 |
# File 'lib/gitlab/multi_destination_logger.rb', line 5 def close loggers.each(&:close) end |