Sha256: d509b01f7dfb9b6d295b721a9db41c1a45c2e0db7e7454176a67c6dd84c276dd
Contents?: true
Size: 580 Bytes
Versions: 9
Compression:
Stored size: 580 Bytes
Contents
require "logstash/filters/base" require "logstash/namespace" require "ostruct" class LogStash::Filters::Field < LogStash::Filters::Base class EvalSpace < OpenStruct def get_binding return binding end end public def register # nothing to do end # def register public def filter(event) data = EvalSpace.new(event.to_hash) @config.each do |condition| if data.instance_eval(condition) return # This event is OK, matches the condition. end end event.cancel end # def filter end # class LogStash::Filters::Field
Version data entries
9 entries across 9 versions & 1 rubygems