Skip to content

Instantly share code, notes, and snippets.

@Aeon
Last active August 29, 2015 14:01
Show Gist options
  • Save Aeon/083ade02142bff1d4663 to your computer and use it in GitHub Desktop.
Save Aeon/083ade02142bff1d4663 to your computer and use it in GitHub Desktop.
#!/usr/bin/env ruby
require 'resque'
Resque.redis.namespace = "resque:#{ENV['APP_NAME']}"
while Resque::Failure.count > 0 do |i|
job = Resque::Failure.all(0,1)
unless !job || job['retried_at'].nil?
Resque::Failure.remove(0)
else
break
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment