Commit bd2084f3 authored by Pablo Carranza's avatar Pablo Carranza

Change migration to support building index concurrently

parent a5238840
class AddFingerprintIndex < ActiveRecord::Migration
disable_ddl_transaction!
def change
add_index :keys, :fingerprint
args = [:keys, :fingerprint]
if Gitlab::Database.postgresql?
args << { algorithm: :concurrently }
end
add_index(*args)
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment