diff options
Diffstat (limited to 'db/post_migrate/20200217225719_schedule_migrate_security_scans.rb')
-rw-r--r-- | db/post_migrate/20200217225719_schedule_migrate_security_scans.rb | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/db/post_migrate/20200217225719_schedule_migrate_security_scans.rb b/db/post_migrate/20200217225719_schedule_migrate_security_scans.rb deleted file mode 100644 index 087c189f9fd..00000000000 --- a/db/post_migrate/20200217225719_schedule_migrate_security_scans.rb +++ /dev/null @@ -1,31 +0,0 @@ -# frozen_string_literal: true - -class ScheduleMigrateSecurityScans < ActiveRecord::Migration[5.2] - include Gitlab::Database::MigrationHelpers - - DOWNTIME = false - INTERVAL = 2.minutes.to_i - BATCH_SIZE = 10_000 - MIGRATION = 'MigrateSecurityScans' - - disable_ddl_transaction! - - class JobArtifact < ActiveRecord::Base - include ::EachBatch - - self.table_name = 'ci_job_artifacts' - - scope :security_reports, -> { where('file_type BETWEEN 5 and 8') } - end - - def up - queue_background_migration_jobs_by_range_at_intervals(JobArtifact.security_reports, - MIGRATION, - INTERVAL, - batch_size: BATCH_SIZE) - end - - def down - # intentionally blank - end -end |