diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-08 00:07:50 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-01-08 00:07:50 +0300 |
commit | d203316c80aa27cf747aa29df9f7c2d374965b5f (patch) | |
tree | aab5cde76fbf19a2639f6f9f3cb4f2acdc95f803 /db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb | |
parent | 8dafc3b65aeb8f50fdfc38fb98d96c3db9e2f607 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb')
-rw-r--r-- | db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb b/db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb new file mode 100644 index 00000000000..758838cb775 --- /dev/null +++ b/db/migrate/20191225071320_add_index_to_elasticsearch_indexed_namespaces.rb @@ -0,0 +1,17 @@ +# frozen_string_literal: true + +class AddIndexToElasticsearchIndexedNamespaces < ActiveRecord::Migration[5.2] + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + disable_ddl_transaction! + + def up + add_concurrent_index(:elasticsearch_indexed_namespaces, :created_at) + end + + def down + remove_concurrent_index(:elasticsearch_indexed_namespaces, :created_at) + end +end |