lograge icon indicating copy to clipboard operation
lograge copied to clipboard

Using Lograge with other logger

Open LYHuang opened this issue 5 years ago • 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.

LYHuang avatar Mar 19 '19 00:03 LYHuang

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 👌

braxtonj avatar Sep 30 '21 00:09 braxtonj