November 2010
2 posts
Retry and clear failed Resque jobs
This is for posterity’s sake :) Retry all jobs: (Resque::Failure.count-1).downto(0).each { |i| Resque::Failure.requeue(i) } Retry jobs for a particular worker: (Resque::Failure.count-1).downto(0).each { |i| payload_class = Resque::Failure.all(i)['payload']['class'] Resque::Failure.requeue(i) if payload_class == 'MyWorker' } Clear failed jobs: Resque::Failure.clear You...
Nov 17th
Performing Disk Repairs on OSX without Install...
I dont travel with my OSX install disk (seriously, who does?) and found myself in a situation where i needed to repair my macbook pro’s hard drive using said installation disk. There are two options if you find yourself in a similar position: Start in safe mode: Hold shift down during start up (performs a simple disk scan) Start in single user mode and run fsck: hold down command+s...
Nov 12th