Module: Contrast::Logger::AliasedLogging
- Defined in:
- lib/contrast/logger/aliased_logging.rb
Overview
Our decorator for the Ougai logger allowing for the catching, creating and saving Telemetry exceptions
Constant Summary collapse
- ALIASED_WARN =
'warn'.cs__freeze
- ALIASED_ERROR =
'error'.cs__freeze
- ALIASED_FATAL =
'fatal'.cs__freeze
Instance Method Summary collapse
- #error(message = nil, exception = nil, data = nil, &block) ⇒ Object
- #fatal(message = nil, exception = nil, data = nil, &block) ⇒ Object
- #warn(message = nil, exception = nil, data = nil, &block) ⇒ Object
Instance Method Details
#error(message = nil, exception = nil, data = nil, &block) ⇒ Object
26 27 28 29 30 |
# File 'lib/contrast/logger/aliased_logging.rb', line 26 def error = nil, exception = nil, data = nil, &block # build Telemetry Exclusion build_exception(ALIASED_ERROR, , exception, data) super(, exception, data, &block) end |
#fatal(message = nil, exception = nil, data = nil, &block) ⇒ Object
35 36 37 38 39 |
# File 'lib/contrast/logger/aliased_logging.rb', line 35 def fatal = nil, exception = nil, data = nil, &block # build Telemetry Exclusion build_exception(ALIASED_FATAL, , exception, data) super(, exception, data, &block) end |
#warn(message = nil, exception = nil, data = nil, &block) ⇒ Object
17 18 19 20 21 |
# File 'lib/contrast/logger/aliased_logging.rb', line 17 def warn = nil, exception = nil, data = nil, &block # build Telemetry Exclusion build_exception(ALIASED_WARN, , exception, data) super(, exception, data, &block) end |