High performance, easy to use background job processing library for Ruby using RabbitMQ queues.
- Consumers (servers) are configurable via yaml files.
- Delayed jobs
- Jobs priority (through RabbitMQ Priority Queues)
- Scalable and failure-safe
- Client & Server hooks
- OpenTracing (http://opentracing.io/) instrumentation
- NewRelic instrumentation for sending errors
Add this line to your application’s Gemfile:
“by gem ‘rabbitek’
And then execute:
First, you need configuration file:
consumers: - FirstConsumer - SecondConsumer
threads: 25 parameters: queue: myqueue basic_qos: 20 queue_attributes: arguments: x-max-priority: 10
Create consumer and include
rabbit_options with path to config file and create
perform method same way as on example:
“ class ExampleConsumer include Rabbitek::Consumer
config_file: 'config/rabbitek.yml' def perform(payload, delivery_info, properties) ack!(delivery_info) end
Lastly, run server:
“undle exec rabbitek
You can schedule jobs e.g.:
- more tests!
- dead queue
- CRON jobs
- job batching (run consumer with e.g. max 100 messages at once)
- extended docs and how to
- prometheus metrics
After checking out the repo, run
bin/setup to install dependencies. You can also run
bin/console for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run
bundle exec rake install. To release a new version, update the version number in
version.rb, and then run
bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the
.gem file to rubygems.org.
Bug reports and pull requests are welcome on GitHub at https://github.com/Boostcom/rabbitek.
Please see LICENSE.txt
Boostcom - we provide the most powerful management- and loyalty platform built for the needs of shopping centres.