class FistOfFury::Dispatcher
Public Instance Methods
dispatch(worker, time)
click to toggle source
# File lib/fist_of_fury/dispatcher.rb, line 5 def dispatch(worker, time) enqueue(worker) if worker.scheduled_time_met?(time) rescue StandardError => e # TODO: exception handling support raise e end
Protected Instance Methods
enqueue(worker)
click to toggle source
# File lib/fist_of_fury/dispatcher.rb, line 14 def enqueue(worker) klass = worker.to_s info "Enqueue: #{klass}" worker.new.async.perform rescue StandardError => e # TODO: exception handling support raise e end