Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorMayra Cabrera <mcabrera@gitlab.com>2018-04-06 21:54:39 +0300
committerMayra Cabrera <mcabrera@gitlab.com>2018-04-07 05:20:17 +0300
commitd6450717abefbe4dbf891cb4d285f6c84e44f168 (patch)
tree07989446eafbe7a5aa3a7bab2dfedf708777224a /db
parent18a1569319af918fe3aff7564e344143d04d6aca (diff)
Modifies index on DeployTokens to use id
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20180319190020_create_deploy_tokens.rb2
-rw-r--r--db/schema.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/db/migrate/20180319190020_create_deploy_tokens.rb b/db/migrate/20180319190020_create_deploy_tokens.rb
index 318ad3f0610..d129459ea0a 100644
--- a/db/migrate/20180319190020_create_deploy_tokens.rb
+++ b/db/migrate/20180319190020_create_deploy_tokens.rb
@@ -13,7 +13,7 @@ class CreateDeployTokens < ActiveRecord::Migration
t.string :name, null: false
t.string :token, index: { unique: true }, null: false
- t.index [:token, :expires_at], where: "(revoked IS FALSE)"
+ t.index [:token, :expires_at, :id], where: "(revoked IS FALSE)"
end
end
end
diff --git a/db/schema.rb b/db/schema.rb
index a50c5fba969..fd75b176318 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -693,7 +693,7 @@ ActiveRecord::Schema.define(version: 20180405142733) do
t.string "token", null: false
end
- add_index "deploy_tokens", ["token", "expires_at"], name: "index_deploy_tokens_on_token_and_expires_at", where: "(revoked IS FALSE)", using: :btree
+ add_index "deploy_tokens", ["token", "expires_at", "id"], name: "index_deploy_tokens_on_token_and_expires_at_and_id", where: "(revoked IS FALSE)", using: :btree
add_index "deploy_tokens", ["token"], name: "index_deploy_tokens_on_token", unique: true, using: :btree
create_table "deployments", force: :cascade do |t|