0.0
No commit activity in last 3 years
No release in over 3 years
A small modification of Sneaker's built-in Maxretry class has the exact same logic, except you can use RabbitMQ's shovel plugin to manually re-enqueue the messages which failed all of their retries
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies
 Project Readme

Sneakers-Retry

A modified retry handler for RabbitMQ and Sneakers

A small modification of Sneaker's built-in Maxretry class the replacement class is called SneakersRetry::Handlers::Maxretry2 has the exact same logic, except that when a message fails all retries, this handler stores the final failure (the message) in same format as the original message, allowing you to use RabbitMQ's shovel plugin to manually re-enqueue the messages who failed all retries Something that is sometimes needed in production systems

Installation

Include it in your Gemfile.

$ cat Gemfile
...
gem 'sneakers-retry'
...

Next install it with Bundler.

$ bundle install

Use:

read documentation for Sneakers initialize your worker with the Maxretry2 handler:

class MyWorker
  ...
   from_queue 'audit_service', {
      handler: SneakersRetry::Handlers::Maxretry2,
      ...
   }
   ...
end