Skip to content

Instantly share code, notes, and snippets.

@danielvlopes
Created April 13, 2010 04:29
Show Gist options
  • Save danielvlopes/364316 to your computer and use it in GitHub Desktop.
Save danielvlopes/364316 to your computer and use it in GitHub Desktop.
Delayed::Worker.backend = :active_record
Delayed::Worker.destroy_failed_jobs = false
Delayed::Worker.sleep_delay = 60
Delayed::Worker.max_attempts = 25
Delayed::Worker.max_run_time = 5.minutes
class Delayed::Worker
alias_method :original_handle_failed_job, :handle_failed_job
protected
def handle_failed_job(job, error)
HoptoadNotifier.notify(error)
original_handle_failed_job(job,error)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment