Commit 3d405a69 authored by Matija Čupić's avatar Matija Čupić

Add cache_index migration

parent 67973309
# See http://doc.gitlab.com/ce/development/migration_style_guide.html
# for more information on how to write migrations for GitLab.
class AddCacheIndexToProject < ActiveRecord::Migration
include Gitlab::Database::MigrationHelpers
# Set this constant to true if this migration requires downtime.
DOWNTIME = false
disable_ddl_transaction!
def up
add_column_with_default(:projects, :cache_index, :integer, default: 0)
end
def down
remove_column(:projects, :cache_index)
end
end
......@@ -1872,7 +1872,7 @@ ActiveRecord::Schema.define(version: 20171229225929) do
t.boolean "remote_mirror_available_overridden"
t.boolean "only_mirror_protected_branches"
t.boolean "pull_mirror_available_overridden"
t.integer "jobs_cache_index"
t.integer "cache_index", default: 0, null: false
end
add_index "projects", ["ci_id"], name: "index_projects_on_ci_id", using: :btree
......
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