Skip to content

Add rake task for batched bg migration status

Patrick Bair requested to merge pb-batched-migration-status-rake-task into master

What does this MR do and why?

Adds a rake task which prints out the status and primary fields of a batched background migration. This information can be then be fed into the task to finalize these migrations, in instances where they don't complete automatically.

How to set up and validate locally

Run the rake task:

rails gitlab:background_migrations:status

The output should be similar to:

finished   | CopyColumnUsingBackgroundMigrationJob,events,id,[["id","id_convert_to_bigint"]]
paused     | CopyColumnUsingBackgroundMigrationJob,events,id,[["id","id_convert_to_bigint"]]

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Patrick Bair

Merge request reports