diff --git a/db/docs/batched_background_migrations/rerun_epic_dates_to_work_item_dates_sources_sync.yml b/db/docs/batched_background_migrations/rerun_epic_dates_to_work_item_dates_sources_sync.yml index 2ab090dd1f7dfa5ed44baf74428a7906a443a48c..458304b24bb55dd683f11347f8d9e4c87bddc1d3 100644 --- a/db/docs/batched_background_migrations/rerun_epic_dates_to_work_item_dates_sources_sync.yml +++ b/db/docs/batched_background_migrations/rerun_epic_dates_to_work_item_dates_sources_sync.yml @@ -1,9 +1,10 @@ --- migration_job_name: RerunEpicDatesToWorkItemDatesSourcesSync -description: > - We backfilled work_item_dates_sources with epic dates data in 17.1, - but we now need to re-do the migration due to a fix in the syncing mechanism in 17.4. +description: 'We backfilled work_item_dates_sources with epic dates data in 17.1, + but we now need to re-do the migration due to a fix in the syncing mechanism in + 17.4.' feature_category: team_planning introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/162876 milestone: '17.4' queued_migration_version: 20240816110844 +finalized_by: '20250304231739' diff --git a/db/post_migrate/20250304231739_finalize_hk_rerun_epic_dates_to_work_item_dates_sources_sync.rb b/db/post_migrate/20250304231739_finalize_hk_rerun_epic_dates_to_work_item_dates_sources_sync.rb new file mode 100644 index 0000000000000000000000000000000000000000..995ac625a9fc0512cfe95db047ff865ba9a890ae --- /dev/null +++ b/db/post_migrate/20250304231739_finalize_hk_rerun_epic_dates_to_work_item_dates_sources_sync.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +class FinalizeHkRerunEpicDatesToWorkItemDatesSourcesSync < Gitlab::Database::Migration[2.2] + milestone '17.10' + + disable_ddl_transaction! + + restrict_gitlab_migration gitlab_schema: :gitlab_main + + def up + ensure_batched_background_migration_is_finished( + job_class_name: 'RerunEpicDatesToWorkItemDatesSourcesSync', + table_name: :epics, + column_name: :id, + job_arguments: [], + finalize: true + ) + end + + def down; end +end diff --git a/db/schema_migrations/20250304231739 b/db/schema_migrations/20250304231739 new file mode 100644 index 0000000000000000000000000000000000000000..77821479e8071bc36da3481651a143abbdea6fce --- /dev/null +++ b/db/schema_migrations/20250304231739 @@ -0,0 +1 @@ +a564ed03b1aaab641277b56b6f94bc422c20258a082cef24358a477f94e43a28 \ No newline at end of file