class LogStash::Filters::Dissect

Public Instance Methods

filter(event) click to toggle source
# File lib/logstash/filters/dissect.rb, line 175
def filter(event)
  # all plugin functions happen in the JRuby extension:
  # debug, warn and error logging, filter_matched, tagging etc.
  @dissector.dissect(event)
end
increment_failures_metric() click to toggle source

the JRuby Extension `initialize` method stores a DynamicMethod reference to this method

# File lib/logstash/filters/dissect.rb, line 199
def increment_failures_metric
  metric_increment(:failures)
end
increment_matches_metric() click to toggle source

the JRuby Extension `initialize` method stores a DynamicMethod reference to this method

# File lib/logstash/filters/dissect.rb, line 194
def increment_matches_metric
  metric_increment(:matches)
end
metric_increment(metric_name) click to toggle source

this method is stubbed during testing a reference to it in the JRuby Extension `initialize` may not be valid

# File lib/logstash/filters/dissect.rb, line 189
def metric_increment(metric_name)
  metric.increment(metric_name)
end
multi_filter(events) click to toggle source
# File lib/logstash/filters/dissect.rb, line 181
def multi_filter(events)
  LogStash::Util.set_thread_plugin(self)
  @dissector.dissect_multi(events)
  events
end
register() click to toggle source
# File lib/logstash/filters/dissect.rb, line 170
def register
  needs_decoration = @add_field.size + @add_tag.size + @remove_field.size + @remove_tag.size > 0
  @dissector = LogStash::Dissector.new(@mapping, self, @convert_datatype, needs_decoration)
end