From c73d5a6075d6a6ef9cbfc84e34015603d5126982 Mon Sep 17 00:00:00 2001 From: Jaehong Kang Date: Wed, 8 Nov 2023 22:15:43 +0900 Subject: [PATCH] Using Sidekiq concurrency for default db pool value (#26488) --- config/database.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/database.yml b/config/database.yml index b995f2317..2898415d8 100644 --- a/config/database.yml +++ b/config/database.yml @@ -1,6 +1,6 @@ default: &default adapter: postgresql - pool: <%= ENV["DB_POOL"] || ENV['MAX_THREADS'] || 5 %> + pool: <%= ENV["DB_POOL"] || (if Sidekiq.server? then Sidekiq[:concurrency] else ENV['MAX_THREADS'] end) || 5 %> timeout: 5000 connect_timeout: 15 encoding: unicode