Class: Fluent::Rds_GenlogInput::TimerWatcher
- Inherits:
-
Coolio::TimerWatcher
- Object
- Coolio::TimerWatcher
- Fluent::Rds_GenlogInput::TimerWatcher
- Defined in:
- lib/fluent/plugin/in_rds_genlog.rb
Instance Method Summary collapse
-
#initialize(interval, repeat, log, &callback) ⇒ TimerWatcher
constructor
A new instance of TimerWatcher.
- #on_timer ⇒ Object
Constructor Details
#initialize(interval, repeat, log, &callback) ⇒ TimerWatcher
Returns a new instance of TimerWatcher.
99 100 101 102 103 |
# File 'lib/fluent/plugin/in_rds_genlog.rb', line 99 def initialize(interval, repeat, log, &callback) @callback = callback @log = log super(interval, repeat) end |
Instance Method Details
#on_timer ⇒ Object
105 106 107 108 109 110 |
# File 'lib/fluent/plugin/in_rds_genlog.rb', line 105 def on_timer @callback.call rescue => e @log.error(e.) @log.error_backtrace(e.backtrace) end |