Fix Inconsistent index_design_management_versions index
What does this MR do and why?
The index index_design_management_versions_on_author_id
was added in this MR. For some, unknown reason we could not find it in our production database.
I am adding the index back to avoid inconsistency between our Gitlab.com and self-host databases.
up:
== 20220116175851 AddAuthorIndexToDesignManagementVersions: migrating =========
-- transaction_open?()
-> 0.0000s
-- index_exists?(:design_management_versions, :author_id, {:where=>"author_id IS NOT NULL", :name=>"index_design_management_versions_on_author_id", :algorithm=>:concurrently})
-> 0.0065s
-- Index not created because it already exists (this may be due to an aborted migration or similar): table_name: design_management_versions, column_name: author_id
== 20220116175851 AddAuthorIndexToDesignManagementVersions: migrated (0.0098s)
down:
== 20220116175851 AddAuthorIndexToDesignManagementVersions: reverting =========
-- transaction_open?()
-> 0.0000s
-- index_exists?(:design_management_versions, :author_id, {:name=>"index_design_management_versions_on_author_id", :algorithm=>:concurrently})
-> 0.0036s
-- execute("SET statement_timeout TO 0")
-> 0.0004s
-- remove_index(:design_management_versions, {:name=>"index_design_management_versions_on_author_id", :algorithm=>:concurrently, :column=>:author_id})
-> 0.0042s
-- execute("RESET statement_timeout")
-> 0.0005s
== 20220116175851 AddAuthorIndexToDesignManagementVersions: reverted (0.0105s)
Screenshots or screen recordings
These are strongly recommended to assist reviewers and reduce the time to merge your change.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #349549 (closed)
Edited by Mayra Cabrera