Skip to content

Instantly share code, notes, and snippets.

@betawaffle
Created October 14, 2011 11:21
Show Gist options
  • Save betawaffle/1286843 to your computer and use it in GitHub Desktop.
Save betawaffle/1286843 to your computer and use it in GitHub Desktop.
old = Resque.working.select do |w|
w.processing['run_at'].to_datetime < 5.minutes.ago
end
old.each { |w| Process.kill('USR1', w.pid) }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment