diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-11-14 11:41:52 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-11-14 11:41:52 +0300 |
commit | 585826cb22ecea5998a2c2a4675735c94bdeedac (patch) | |
tree | 5b05f0b30d33cef48963609e8a18a4dff260eab3 /db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb | |
parent | df221d036e5d0c6c0ee4d55b9c97f481ee05dee8 (diff) |
Add latest changes from gitlab-org/gitlab@16-6-stable-eev16.6.0-rc42
Diffstat (limited to 'db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb')
-rw-r--r-- | db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb b/db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb new file mode 100644 index 00000000000..a5688a9b196 --- /dev/null +++ b/db/post_migrate/20231023164908_async_drop_index_users_on_accepted_term_id.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +class AsyncDropIndexUsersOnAcceptedTermId < Gitlab::Database::Migration[2.2] + milestone '16.6' + disable_ddl_transaction! + + TABLE_NAME = 'users' + INDEX_NAME = 'index_users_on_accepted_term_id' + COLUMN = 'accepted_term_id' + + # TODO: Index to be destroyed synchronously in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/135293 + def up + prepare_async_index_removal TABLE_NAME, COLUMN, name: INDEX_NAME + end + + def down + prepare_async_index_removal TABLE_NAME, COLUMN, name: INDEX_NAME + end +end |