Sha256: 0a362813f8137e67e6be881deeba1fcf4d61badb2eb262456f864244daf9d7cc

Contents?: true

Size: 662 Bytes

Versions: 2

Compression:

Stored size: 662 Bytes

Contents

require_relative 'core'

module Fluent
  class RecordReformerOutput < Output
    Fluent::Plugin.register_output('record_reformer', self)

    include ::Fluent::RecordReformerOutputCore

    def initialize
      super
    end

    # To support log_level option implemented by Fluentd v0.10.43
    unless method_defined?(:log)
      define_method("log") { $log }
    end

    # Define `router` method of v0.12 to support v0.10 or earlier
    unless method_defined?(:router)
      define_method("router") { Fluent::Engine }
    end

    def configure(conf)
      super
    end

    def emit(tag, es, chain)
      process(tag, es)
      chain.next
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
fluent-plugin-record-reformer-0.9.1 lib/fluent/plugin/out_record_reformer/v12.rb
fluent-plugin-record-reformer-0.9.0 lib/fluent/plugin/out_record_reformer/v12.rb