diff options
Diffstat (limited to 'db/post_migrate/20230404044338_drop_async_index_ci_job_artifacts_on_expire_at_for_removal.rb')
-rw-r--r-- | db/post_migrate/20230404044338_drop_async_index_ci_job_artifacts_on_expire_at_for_removal.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/db/post_migrate/20230404044338_drop_async_index_ci_job_artifacts_on_expire_at_for_removal.rb b/db/post_migrate/20230404044338_drop_async_index_ci_job_artifacts_on_expire_at_for_removal.rb new file mode 100644 index 00000000000..7c3cb65c884 --- /dev/null +++ b/db/post_migrate/20230404044338_drop_async_index_ci_job_artifacts_on_expire_at_for_removal.rb @@ -0,0 +1,14 @@ +# frozen_string_literal: true + +class DropAsyncIndexCiJobArtifactsOnExpireAtForRemoval < Gitlab::Database::Migration[2.1] + INDEX_NAME = 'index_ci_job_artifacts_on_expire_at_for_removal' + + # TODO: Index to be destroyed synchronously in https://gitlab.com/gitlab-org/gitlab/-/issues/393913 + def up + prepare_async_index_removal :ci_job_artifacts, :expire_at, name: INDEX_NAME + end + + def down + unprepare_async_index :ci_job_artifacts, :expire_at, name: INDEX_NAME + end +end |