Class: LogStash::Codecs::Plain
- Defined in:
- lib/logstash/codecs/plain.rb
Overview
The “plain” codec is for plain text with no delimiting between events.
This is mainly useful on inputs and outputs that already have a defined framing in their transport protocol (such as zeromq, rabbitmq, redis, etc)
Constant Summary
Constants included from LogStash::Config::Mixin
LogStash::Config::Mixin::CONFIGSORT
Instance Attribute Summary
Attributes included from LogStash::Config::Mixin
Attributes inherited from Plugin
Instance Method Summary collapse
- #decode(data) {|LogStash::Event.new("message" => @converter.convert(data))| ... } ⇒ Object
- #encode(data) ⇒ Object
- #register ⇒ Object
Methods inherited from Base
#clone, #flush, #initialize, #on_event, #teardown
Methods included from LogStash::Config::Mixin
Methods inherited from Plugin
#eql?, #finished, #finished?, #hash, #initialize, #inspect, lookup, #reload, #running?, #shutdown, #teardown, #terminating?, #to_s
Constructor Details
This class inherits a constructor from LogStash::Codecs::Base
Instance Method Details
#decode(data) {|LogStash::Event.new("message" => @converter.convert(data))| ... } ⇒ Object
35 36 37 |
# File 'lib/logstash/codecs/plain.rb', line 35 def decode(data) yield LogStash::Event.new("message" => @converter.convert(data)) end |