-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Throttling queues #7
Comments
You should be able to do this by using the same sidekiq_options queue: :critical, throttle: { key: :critical, threshold: 20, period: 1.hour } Is this the solution you're looking for? |
@gevans ah, didn't realize the key was shared across workers. So this would look something like the following? class FooWorker
include Sidekiq::Worker
sidekiq_options queue: :critical, throttle: { key: :critical, threshold: 20, period: 1.hour }
end
class BarWorker
include Sidekiq::Worker
sidekiq_options queue: :critical, throttle: { key: :critical, threshold: 20, period: 1.hour }
end |
Exactly. :) The readme needs to be organized a bit better. The So |
@gevans appreciate the prompt response. Will let you know if I have any more issues. |
It would be great if users could throttle an entire queue, regardless of which worker was running on it. In my case, I have ~15 job types that all need to respect the same rate limit.
The text was updated successfully, but these errors were encountered: