roidrage/lograge

Using Lograge with other logger

Opened this issue · 1 comments

Hello,

I am currently try to use lograge and logdna-rails in my application, logdna-rails can send the log to the cloud platform.

At first I am using the setting like this:

config.lograge.enabled = true
config.lograge.logger = Logdna::RailsLogger.new('apiKey', options)

However I notice that lograge will change the behavior of default logger and not calling the log function in logdna-rails.

I also try this setting:

config.lograge.enabled = true
config.lograge.keep_original_rails_log = true
config.logger = Logdna::RailsLogger.new('apiKey', options)

This one is sending the log, but it doesn't format by the lograge, is there any way to set up the custom logger for the lograge? Thank you.

Hey @LYHuang!

Sadly a bit late but check out our blog post on this and the example repo detailing Lograge implementation with LogDNA if you are still having trouble 👌