|
|
@ -15,12 +15,13 @@ end |
|
|
|
|
|
|
|
Rails.configuration.after_initialize do |
|
|
|
RailsSemanticLogger::Rack::Logger.logger.level = :info # useful for remaining log like "[Rack::Log] Started..." |
|
|
|
SemanticLogger.default_level = :debug |
|
|
|
Rails.logger.name = 'rails' |
|
|
|
|
|
|
|
if Rails.env.production? |
|
|
|
|
|
|
|
appender = :syslog |
|
|
|
formatter = Rails.application.config.x.semantic.formatter.constantize.new |
|
|
|
SemanticLogger.add_appender(appender: :syslog, formatter:) |
|
|
|
SemanticLogger.add_appender(appender:, formatter:) |
|
|
|
Semantic::Instrumentalizer.activate(*build_instrumentation_config) |
|
|
|
|
|
|
|
else |
|
|
|