diff options
Diffstat (limited to 'db/migrate/20190910114843_exclude_nulls_from_index_on_namespaces_type.rb')
-rw-r--r-- | db/migrate/20190910114843_exclude_nulls_from_index_on_namespaces_type.rb | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/db/migrate/20190910114843_exclude_nulls_from_index_on_namespaces_type.rb b/db/migrate/20190910114843_exclude_nulls_from_index_on_namespaces_type.rb deleted file mode 100644 index 8237c48b16d..00000000000 --- a/db/migrate/20190910114843_exclude_nulls_from_index_on_namespaces_type.rb +++ /dev/null @@ -1,20 +0,0 @@ -# frozen_string_literal: true - -class ExcludeNullsFromIndexOnNamespacesType < ActiveRecord::Migration[5.1] - include Gitlab::Database::MigrationHelpers - - # Set this constant to true if this migration requires downtime. - DOWNTIME = false - - disable_ddl_transaction! - - def up - add_concurrent_index(:namespaces, :type, where: 'type is not null', name: 'index_namespaces_on_type_partial') - remove_concurrent_index_by_name(:namespaces, 'index_namespaces_on_type') - end - - def down - add_concurrent_index(:namespaces, :type, name: 'index_namespaces_on_type') - remove_concurrent_index_by_name(:namespaces, 'index_namespaces_on_type_partial') - end -end |