Class: Fluent::DfInputTimerWatcher
- Inherits:
-
Coolio::TimerWatcher
- Object
- Coolio::TimerWatcher
- Fluent::DfInputTimerWatcher
- Defined in:
- lib/fluent/plugin/in_df.rb
Instance Method Summary collapse
-
#initialize(interval, repeat, &callback) ⇒ DfInputTimerWatcher
constructor
A new instance of DfInputTimerWatcher.
- #on_timer ⇒ Object
Constructor Details
#initialize(interval, repeat, &callback) ⇒ DfInputTimerWatcher
80 81 82 83 |
# File 'lib/fluent/plugin/in_df.rb', line 80 def initialize(interval, repeat, &callback) @callback = callback super(interval, repeat) end |
Instance Method Details
#on_timer ⇒ Object
85 86 87 88 89 |
# File 'lib/fluent/plugin/in_df.rb', line 85 def on_timer @callback.call rescue => e $log.error "#{e.class.name} - #{e.message}" end |