Class: Fluent::FormatOutput
- Inherits:
-
Output
- Object
- Output
- Fluent::FormatOutput
- Defined in:
- lib/fluent/plugin/out_format.rb
Constant Summary collapse
- CONF_KEYS =
%w{type tag include_original_fields}
Instance Method Summary collapse
Instance Method Details
#configure(conf) ⇒ Object
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/fluent/plugin/out_format.rb', line 10 def configure(conf) super @fields = {} conf.each do |k, v| unless CONF_KEYS.include?(k) @fields[k] = v end end end |
#emit(tag, es, chain) ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/fluent/plugin/out_format.rb', line 21 def emit(tag, es, chain) es.each do |time, record| Engine.emit(@tag, time, format_record(record)) end chain.next end |