Merge branch 'master' into 14715-keepprox-config
[arvados.git] / services / api / db / migrate / 20140421151939_rename_auth_keys_user_index.rb
1 # Copyright (C) The Arvados Authors. All rights reserved.
2 #
3 # SPDX-License-Identifier: AGPL-3.0
4
5 class RenameAuthKeysUserIndex < ActiveRecord::Migration[4.2]
6   # Rails' default name for this index is so long, Rails can't modify
7   # the index later, because the autogenerated temporary name exceeds
8   # PostgreSQL's 64-character limit.  This migration gives the index
9   # an explicit name to work around that issue.
10   def change
11     rename_index("authorized_keys",
12                  "index_authorized_keys_on_authorized_user_uuid_and_expires_at",
13                  "index_authkeys_on_user_and_expires_at")
14   end
15 end