Class: GrapeLogging::Formatters::Logstash
- Inherits:
-
Object
- Object
- GrapeLogging::Formatters::Logstash
- Defined in:
- lib/grape_logging/formatters/logstash.rb
Instance Method Summary collapse
Instance Method Details
#call(severity, datetime, _, data) ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/grape_logging/formatters/logstash.rb', line 4 def call(severity, datetime, _, data) { :'@timestamp' => datetime.iso8601, :'@version' => '1', :severity => severity }.merge!(format(data)).to_json + "\n" end |