Skip to content

Instantly share code, notes, and snippets.

@JustinChristensen
Created February 28, 2012 21:49
Show Gist options
  • Save JustinChristensen/1935385 to your computer and use it in GitHub Desktop.
Save JustinChristensen/1935385 to your computer and use it in GitHub Desktop.
Delayed::Worker.max_attempts = 25
Delayed::Worker.destroy_failed_jobs = true # destroy after 25 attempts
Delayed::Worker.default_priority = 10 # otherwise defaults to 0 and lower numbers run first
# Only use delayed_job if we're in production or if you explicitly set it.
Delayed::Worker.delay_jobs = Rails.env.production? || ENV['DELAYED_JOB']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment