Search code examples
ruby-on-railssidekiq

Does the Sidekiq API not show all available queues?


My sidekiq.yml config file defines the following queues

---

:queues:
  - [high_priority, 2]
  - mailers
  - default
  - low_priority

When Sidekiq starts up with the app, the app log correctly shows that the queues were picked up

...
Booting Sidekiq 3.5.0 with redis options {:url=>"redis://localhost:6379/", :network_timeout=>3}
...
Starting processing, hit Ctrl-C to stop
{:queues=>["high_priority", "high_priority", "mailers", "default", "low_priority"], :labels=>[], ...

But when I try using the Sidekiq API to retrieve the list of queues from the rails console, I only see the default queue

> Sidekiq::Queue.all
=> [#<Sidekiq::Queue:0x000001061f4760 @name="default", @rname="queue:default">]

Any reason the API doesn't return all queues?


Solution

  • Queues aren't created in Redis until a job is pushed to them.