Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-12-20 17:22:11 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-12-20 17:22:11 +0300
commit0c872e02b2c822e3397515ec324051ff540f0cd5 (patch)
treece2fb6ce7030e4dad0f4118d21ab6453e5938cdd /sidekiq_cluster/sidekiq_cluster.rb
parentf7e05a6853b12f02911494c4b3fe53d9540d74fc (diff)
Add latest changes from gitlab-org/gitlab@15-7-stable-eev15.7.0-rc42
Diffstat (limited to 'sidekiq_cluster/sidekiq_cluster.rb')
-rw-r--r--sidekiq_cluster/sidekiq_cluster.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/sidekiq_cluster/sidekiq_cluster.rb b/sidekiq_cluster/sidekiq_cluster.rb
index c68cbe7c163..1ed08e7e839 100644
--- a/sidekiq_cluster/sidekiq_cluster.rb
+++ b/sidekiq_cluster/sidekiq_cluster.rb
@@ -1,6 +1,7 @@
# frozen_string_literal: true
require_relative '../lib/gitlab/process_management'
+require_relative '../lib/gitlab/process_supervisor'
module Gitlab
module SidekiqCluster
@@ -33,8 +34,9 @@ module Gitlab
#
# directory - The directory of the Rails application.
#
- # Returns an Array containing the PIDs of the started processes.
- def self.start(queues, env: :development, directory: Dir.pwd, max_concurrency: 50, min_concurrency: 0, timeout: DEFAULT_SOFT_TIMEOUT_SECONDS, dryrun: false)
+ # Returns an Array containing the waiter threads (from Process.detach) of
+ # the started processes.
+ def self.start(queues, env: :development, directory: Dir.pwd, max_concurrency: 20, min_concurrency: 0, timeout: DEFAULT_SOFT_TIMEOUT_SECONDS, dryrun: false)
queues.map.with_index do |pair, index|
start_sidekiq(pair, env: env,
directory: directory,
@@ -82,9 +84,7 @@ module Gitlab
)
end
- ProcessManagement.wait_async(pid)
-
- pid
+ Process.detach(pid)
end
def self.count_by_queue(queues)