Rack Middleware; All request logger for web application.
Add this line to your application's Gemfile:
gem 'request_logger', git: 'https://github.com/t-cyrill/request_logger.git'
And then execute:
$ bundle
Write use RequestLogger::Logger
In your config.ru
ie. Rails4
use RequestLogger::Logger, Logger.new(Rails.root.join('log', 'request.log')), 128, 10
Second parameter is required. You must set Logger.
Third parameter is optional. It's size limitation in each parameter and cookies.
ie. Too long post parameter in foo
, {foo: "[FILTERED Too large (... bytes)] ....."}
Forth parameter is also optional. It's view limitation overed size limitation.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request