A lightweight Resque plugin to log whenever a job is enqueued. Super handy for debugging! 😄
Add to your Gemfile:
gem "resque-enqueue-logging"
Just extend Resque::Plugins::EnqueueLogging and all the hooks will be set up.
classSortUserJobextendResque::Plugins::EnqueueLogging@queue=:lowdefperform(user_id,options={})# do hard workendendResque.enqueueSortUserJob,1,:force=>trueIn the logfile:
Enqueued SortUserJob to "low": user_id=1, options={"force"=>true}
- Add tests
- Add CI configuration (and test coverage badge)