diff options
author | Alejandro RodrÃguez <alejorro70@gmail.com> | 2016-08-03 02:35:48 +0300 |
---|---|---|
committer | Alejandro RodrÃguez <alejorro70@gmail.com> | 2016-08-03 23:43:45 +0300 |
commit | efef0be2352a7a2ca769c1db0560a76fbe36b9a3 (patch) | |
tree | 69e4189471b8e3fc7c9bc810f5a3e75c7b008e11 /db | |
parent | 6a9283600cd4a11b97fe26772e68095d8dc854bd (diff) |
Remove unnecessary index_projects_on_builds_enabled index from the projects table
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20160802010328_remove_builds_enable_index_on_projects.rb | 9 | ||||
-rw-r--r-- | db/schema.rb | 3 |
2 files changed, 10 insertions, 2 deletions
diff --git a/db/migrate/20160802010328_remove_builds_enable_index_on_projects.rb b/db/migrate/20160802010328_remove_builds_enable_index_on_projects.rb new file mode 100644 index 00000000000..5fd51cb65f1 --- /dev/null +++ b/db/migrate/20160802010328_remove_builds_enable_index_on_projects.rb @@ -0,0 +1,9 @@ +class RemoveBuildsEnableIndexOnProjects < ActiveRecord::Migration + include Gitlab::Database::MigrationHelpers + + DOWNTIME = false + + def change + remove_index :projects, column: :builds_enabled if index_exists?(:projects, :builds_enabled) + end +end diff --git a/db/schema.rb b/db/schema.rb index 5b35a528e71..dc28842758a 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended that you check this file into your version control system. -ActiveRecord::Schema.define(version: 20160726093600) do +ActiveRecord::Schema.define(version: 20160802010328) do # These are extensions that must be enabled in order to support this database enable_extension "plpgsql" @@ -852,7 +852,6 @@ ActiveRecord::Schema.define(version: 20160726093600) do end add_index "projects", ["builds_enabled", "shared_runners_enabled"], name: "index_projects_on_builds_enabled_and_shared_runners_enabled", using: :btree - add_index "projects", ["builds_enabled"], name: "index_projects_on_builds_enabled", using: :btree add_index "projects", ["ci_id"], name: "index_projects_on_ci_id", using: :btree add_index "projects", ["created_at", "id"], name: "index_projects_on_created_at_and_id", using: :btree add_index "projects", ["creator_id"], name: "index_projects_on_creator_id", using: :btree |