diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-08-25 21:10:28 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-08-25 21:10:28 +0000 |
commit | 52f765baf4931efd40d10b1eb5f2818923ddf26f (patch) | |
tree | 5cdbe4c6aa08be4b829316b0d80f94d46c305703 /db/migrate | |
parent | b98791fe502a4dfc02b70d3fa4b4140afb69d7d9 (diff) | |
download | gitlab-ce-52f765baf4931efd40d10b1eb5f2818923ddf26f.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'db/migrate')
-rw-r--r-- | db/migrate/20210819152723_remove_tmp_index_approval_project_rules_scanners.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/db/migrate/20210819152723_remove_tmp_index_approval_project_rules_scanners.rb b/db/migrate/20210819152723_remove_tmp_index_approval_project_rules_scanners.rb new file mode 100644 index 00000000000..a60141991a6 --- /dev/null +++ b/db/migrate/20210819152723_remove_tmp_index_approval_project_rules_scanners.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true + +class RemoveTmpIndexApprovalProjectRulesScanners < ActiveRecord::Migration[6.1] + include Gitlab::Database::MigrationHelpers + + disable_ddl_transaction! + + INDEX_NAME = 'tmp_index_approval_project_rules_scanners' + + def up + remove_concurrent_index_by_name :approval_project_rules, INDEX_NAME + end + + def down + add_concurrent_index :approval_project_rules, :scanners, name: INDEX_NAME, using: :gin, where: "scanners @> '{cluster_image_scanning}'" + end +end |