Commit 7fc95d80 authored by Yorick Peterse's avatar Yorick Peterse

Added index on services.template

This column is queried when creating a new project, without an index
this query would lead to a sequence scan.
parent ead3ffd7
class AddServicesTemplateIndex < ActiveRecord::Migration
def change
add_index :services, :template
end
end
......@@ -667,6 +667,7 @@ ActiveRecord::Schema.define(version: 20151026182941) do
add_index "services", ["created_at", "id"], name: "index_services_on_created_at_and_id", using: :btree
add_index "services", ["project_id"], name: "index_services_on_project_id", using: :btree
add_index "services", ["template"], name: "index_services_on_template", using: :btree
create_table "snippets", force: true do |t|
t.string "title"
......
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