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:
Diffstat (limited to 'app/workers/container_registry/record_data_repair_detail_worker.rb')
-rw-r--r--app/workers/container_registry/record_data_repair_detail_worker.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/workers/container_registry/record_data_repair_detail_worker.rb b/app/workers/container_registry/record_data_repair_detail_worker.rb
index 390481f8e01..3e40dbbb99a 100644
--- a/app/workers/container_registry/record_data_repair_detail_worker.rb
+++ b/app/workers/container_registry/record_data_repair_detail_worker.rb
@@ -17,7 +17,7 @@ module ContainerRegistry
LEASE_TIMEOUT = 1.hour.to_i
def perform_work
- return unless Gitlab.com?
+ return unless Gitlab.com_except_jh?
return unless next_project
return if next_project.container_registry_data_repair_detail
@@ -51,7 +51,7 @@ module ContainerRegistry
end
def remaining_work_count
- return 0 unless Gitlab.com?
+ return 0 unless Gitlab.com_except_jh?
return 0 unless Feature.enabled?(:registry_data_repair_worker)
return 0 unless ContainerRegistry::GitlabApiClient.supports_gitlab_api?
@@ -69,7 +69,7 @@ module ContainerRegistry
end
def next_project
- Project.pending_data_repair_analysis.first
+ Project.pending_data_repair_analysis.limit(max_running_jobs * 2).sample
end
strong_memoize_attr :next_project