Module: Datadog::Core::Diagnostics::EnvironmentLogging

Included in:
EnvironmentLogger, Tracing::Diagnostics::EnvironmentLogger
Defined in:
lib/datadog/core/diagnostics/environment_logger.rb

Overview

Base class for EnvironmentLoggers - should allow for easy reporting by users to Datadog support.

The EnvironmentLogger should not pollute the logs in a development environment.

Instance Method Summary collapse

Instance Method Details

#log_configuration!(prefix, data) ⇒ Object



14
15
16
# File 'lib/datadog/core/diagnostics/environment_logger.rb', line 14

def log_configuration!(prefix, data)
  logger.info("DATADOG CONFIGURATION - #{prefix} - #{data}")
end

#log_debug!(prefix, data) ⇒ Object



18
19
20
# File 'lib/datadog/core/diagnostics/environment_logger.rb', line 18

def log_debug!(prefix, data)
  logger.debug("DATADOG CONFIGURATION - #{prefix} - #{data}")
end

#log_error!(prefix, type, error) ⇒ Object



22
23
24
# File 'lib/datadog/core/diagnostics/environment_logger.rb', line 22

def log_error!(prefix, type, error)
  logger.warn("DATADOG ERROR - #{prefix} - #{type}: #{error}")
end