Module: Sidekiq::LimitFetch::Global::Monitor
Constant Summary collapse
- HEARTBEAT_NAMESPACE =
'heartbeat:'
- PROCESSOR_NAMESPACE =
'processor:'
- HEARTBEAT_TTL =
400
- REFRESH_TIMEOUT =
180
Instance Method Summary collapse
Instance Method Details
#start!(ttl = HEARTBEAT_TTL, timeout = REFRESH_TIMEOUT) ⇒ Object
11 12 13 14 15 16 17 18 19 |
# File 'lib/sidekiq/limit_fetch/global/monitor.rb', line 11 def start!(ttl=HEARTBEAT_TTL, timeout=REFRESH_TIMEOUT) Thread.new do loop do update_heartbeat ttl invalidate_old_processors sleep timeout end end end |