Class: Fluent::Plugin::NaisFlattenFilter

Inherits:
Filter
  • Object
show all
Defined in:
lib/fluent/plugin/filter_nais_flatten_record.rb

Instance Method Summary collapse

Instance Method Details

#configure(conf) ⇒ Object



10
11
12
13
# File 'lib/fluent/plugin/filter_nais_flatten_record.rb', line 10

def configure(conf)
  super
  @re = @keep == "" ? nil : Regexp.new(@keep)
end

#filter(tag, time, record) ⇒ Object



15
16
17
# File 'lib/fluent/plugin/filter_nais_flatten_record.rb', line 15

def filter(tag, time, record)
  ::Nais::Log::Parser.flatten_hash(record, "", @re)
end