Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Sidekiq: Clear a Specific Queue

Sidekiq: Clear a Specific Queue

Find the queue by name:

> queue = Sidekiq::Queue.all.detect { |queue| queue.name == 'compliance_requests' }
=> #<Sidekiq::Queue:0x00007fa5c4069778 @name="compliance_requests", @rname="queue:compliance_requests">

Clear the queue:

> queue.clear
=> [0, true]
> queue.clear
=> [0, false]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.