Where can I put my backec code with a retry error?

resque-retry gem README discusses a change in the implementation of the backend during implementation.

MultipleWithRetrySuppression - This is a multiple standby server with suppression of retry.

Here is an example using the Redis error backend:

require 'resque-retry'
require 'resque/failure/redis'

# require your jobs & application code.

Resque::Failure::MultipleWithRetrySuppression.classes = [Resque::Failure::Redis]
Resque::Failure.backend = Resque::Failure::MultipleWithRetrySuppression

If the job fails, but can and will retry, the details of the failure will not be logged in the Redis failed attempts queue (visible via resque-web).

If the job fails, but cannot or will not retry, the crash will be put on the Redis queue as a normal failure (without retrying).

, Rails . , . config/initializers/resque.rb? , ? .

+5
1

, - . , - .

+4

All Articles