Perform sidekiq jobs in time interval
Add this line to your application's Gemfile:
gem 'sidekiq-tip'
And then execute:
$ bundle
Or install it yourself as:
$ gem install sidekiq-tip
class SomeJob
include Sidekiq::Worker
# [0, 0, 0] == [hour, min, sec]
sidekiq_options start_at: [0, 0, 0], finish_at: [10, 0, 0]
def perform
# ...
end
end
- Fork it ( https://github.com/[my-github-username]/sidekiq-tip/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request