best way to re-activate a job
jnicho02 opened this issue · 2 comments
What is the best procedure to re-activate a job that errored due to a system fault that has now been fixed? QueJob does a great job of retrying with backoff and eventually giving up (is that true?).
reset the error_count to 0?
nil out the expired_at date?
Oh, and should I be able to access Que::ActiveRecord::Model in Rails console? I can access Que::ActiveRecord but no Que::ActiveRecord::Model (i've added my own Rails model record to be able access it for now)
I think this would be useful practical help to anyone running live, and should go in the documentation
Just successfully did a
.update(error_count: 0, expired_at: nil)
That update looks good to me. You're right that we should document it. Feel free to PR the docs ;)
Oh, and should I be able to access Que::ActiveRecord::Model in Rails console? I can access Que::ActiveRecord but no Que::ActiveRecord::Model (i've added my own Rails model record to be able access it for now)
I don't have experience with using it in Rails, but I believe you'd need to require 'que/active_record/model'
, and perhaps define the subclass from that example too (as I think you're saying you've done).
eventually giving up (is that true?).
Yeah, that's what expired_at
indicates. See error handling and maximum_retry_count
.