Sha256: 39ba30a223f280dbea795fd0230882de8e69846b8a7e227e0088f8ee4463620a

Contents?: true

Size: 244 Bytes

Versions: 44

Compression:

Stored size: 244 Bytes

Contents

Rack::App::Extension.register(:logger) do

  require "logger"
  require "securerandom"

  define_method(:logger) do
    @logger ||= Rack::App::Logger.new(STDOUT).tap do |this|
      this.id = request.env['HTTP_X_REQUEST_ID']
    end
  end

end

Version data entries

44 entries across 44 versions & 2 rubygems

Version Path
rack-app-8.0.1 lib/rack/app/bundled_extensions/logger.rb
rack-app-8.0.0 lib/rack/app/bundled_extensions/logger.rb
mountapi-0.11.1 vendor/bundle/ruby/2.7.0/gems/rack-app-7.7.0/lib/rack/app/bundled_extensions/logger.rb
rack-app-7.7.0 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.5 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.4 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.3 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.2 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.1 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.6.0 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.5.2 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.5.1 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.5.0 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.4.0 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.3.2 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.3.1 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.3.0 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.2.2 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.2.1 lib/rack/app/bundled_extensions/logger.rb
rack-app-7.2.0 lib/rack/app/bundled_extensions/logger.rb