Skip to content

Latest commit

 

History

History
33 lines (20 loc) · 565 Bytes

README.md

File metadata and controls

33 lines (20 loc) · 565 Bytes

Lumberaxe

Lumberaxe handles logging output formatting.

Usage

After installing the gem, require it as part of your application configuration.

# application.rb

require "lumberaxe/railtie"

Setting JSON logging

To set up JSON logging on puma, add this to your puma config:

# puma.rb

require "lumberaxe"

log_formatter(&Lumberaxe.puma_formatter)

If you don't have a tool for parsing JSON in local development, you can add this:

# development.rb

config.logger = ActiveSupport::TaggedLogging.new(Logger.new($stdout))