Ruby reliable queue implementation on top of Redis. It makes sure that message is not lost between popping it from Redis queue and compeleting the task.
Installation
Add this line to your application's Gemfile:
gem 'reliable-queue-rb', '~> 0.3.0'And then execute:
bundleOr install it yourself as:
gem install reliable-queue-rbUsage
Reliable Queue
queue = ReliableQueue.new(redis_queue, redis_client)
queue.each do |message|
# process message
endChunkedReliableQueue
queue = ChunkedReliableQueue.new(working_on_queue_suffix, redis_queue, redis_client)
queue.each_slice(batch_size) do |messages|
# process array of messages
endContributing
Bug reports and pull requests are welcome on GitHub at https://github.com/altmetric/reliable-queue-rb.
License
Copyright © 2020-2024 Altmetric LLP
Distributed under the MIT License.