Module: LogstashRails::Formatter::Basic
- Defined in:
- lib/logstash_rails/formatter/basic.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.decorate(target, options) ⇒ Object
7 8 9 |
# File 'lib/logstash_rails/formatter/basic.rb', line 7 def self.decorate(target, ) target.extend(self) end |
Instance Method Details
#format(event_type, start, finish, id, payload) ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/logstash_rails/formatter/basic.rb', line 11 def format(event_type, start, finish, id, payload) event_hash = super event_hash.merge!( process_id: $$, host: Socket.gethostname, message: event_type ) # process_action.action_controller events # from Rails4 contain Rack::Request instances # that are not serializable event_hash.delete(:request) event_hash end |