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

partition_management_worker.rb « database « workers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: a203c76558a59ff8d5b8ba59a0f2b7ed4d73ec47 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# frozen_string_literal: true

module Database
  class PartitionManagementWorker
    include ApplicationWorker

    include CronjobQueue # rubocop:disable Scalability/CronWorkerContext

    data_consistency :always

    feature_category :database
    idempotent!

    def perform
      Gitlab::Database::Partitioning::PartitionManager.new.sync_partitions
    ensure
      Gitlab::Database::Partitioning::PartitionMonitoring.new.report_metrics
    end
  end
end