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

batched_migrations.rb « background_migration « database « gitlab « factories « spec - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: de57e0c15651120ca8e101b934afa029c8e84e24 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

FactoryBot.define do
  factory :batched_background_migration, class: '::Gitlab::Database::BackgroundMigration::BatchedMigration' do
    max_value { 10 }
    batch_size { 5 }
    sub_batch_size { 1 }
    interval { 2.minutes }
    job_class_name { 'CopyColumnUsingBackgroundMigrationJob' }
    table_name { :events }
    column_name { :id }
    sequence(:job_arguments) { |n| [["column_#{n}"], ["column_#{n}_convert_to_bigint"]] }
    total_tuple_count { 10_000 }
    pause_ms { 100 }
  end
end