Paritosh Piplewar
Paritosh Piplewar

Reputation: 8124

How to control sidekiq queues concurrency

Assuming I have 5 workers A , B , C , D , E. The first 3 worker belongs to safe queue and last two worker belongs unsafe queue. The unsafe queue worker shouldn't run parallely and safe worker queue can run parallely. And, yes two queues can run parallely.

How do i configure this ?

Upvotes: 1

Views: 1567

Answers (2)

mukesh4139
mukesh4139

Reputation: 76

You can have two Sidekiq Process for safe and unsafe queues. And set the concurrency of the unsafe queue to 1. This will make sure, the unsafe jobs don't run simultaneously.

Upvotes: 2

Altonymous
Altonymous

Reputation: 783

Option 1: Split them into two separate projects and set the concurrency on the unsafe to 1.

Option 2: The sidekiq-unique-jobs gem is not working so well anymore, otherwise, I would recommend it. If you care to fix the issues it's encountering and use it that would be my preference.

Upvotes: 0

Related Questions