Skip to content
Pablo Cantero edited this page Jul 1, 2017 · 20 revisions

Processing Groups is a way to set specific configurations, such as queues, concurrency, delay, long polling for a set of queues or a single queue.

Given this configuration:

concurrency: 25
queues:
  - queue1
  - queue2
  - queue3

Shoryuken will fetch messages from queue1, then queue2 ,then queue3, then repeat it all over again.

Supposing you want to process only one message at time for queue1, but keeping concurrency: 25 for queue2 and queue3, you can that achieve via a group.

concurrency: 25
queues:
  - queue2
  - queue3

groups:
  queue1:
    concurrency: 1
    queues:
      - queue1

Note: If you want make sure to process only one message at time for a given queue, while running multiple Shoryuken processes, have a look at FIFO Queues.

Polling strategy per group

For defining a Polling strategies per group, you can set it a follows:

Shoryuken.configure_server do |config|
  config.options[:queue1][:polling_strategy] = Polling::StrictPriority
end