class Fluent::TailInput::TailWatcher::StatWatcher

Attributes

log[RW]

Public Class Methods

new(path, &callback) click to toggle source
Calls superclass method
# File lib/fluent/plugin/in_tail.rb, line 1072
def initialize(path, &callback)
  @callback = callback
  @log = $log
  super(path)
end

Public Instance Methods

on_change(prev, cur) click to toggle source
# File lib/fluent/plugin/in_tail.rb, line 1080
def on_change(prev, cur)
  @callback.call
rescue
  # TODO log?
  @log.error $!.to_s
  @log.error_backtrace
end