summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorSean McGivern <sean@mcgivern.me.uk>2017-11-06 17:10:18 +0000
committerSean McGivern <sean@mcgivern.me.uk>2017-11-06 17:10:18 +0000
commit045795d0d93dfe426cac668d612aa031114df930 (patch)
tree3a6a1203301ad99af0adac293db5a822bbfe5b27 /db
parent2ea90ffcf1917158d6590999fbee03216ea9bc8c (diff)
parentd934d6504a9f1a706dbfc0b4a28c4cf8dbe8c8eb (diff)
downloadgitlab-ce-045795d0d93dfe426cac668d612aa031114df930.tar.gz
Merge branch 'remove-ensure-ref-fetched-from-controllers' into 'master'
removed the #ensure_ref_fetched from all controllers Closes #36061 See merge request gitlab-org/gitlab-ce!15129
Diffstat (limited to 'db')
-rw-r--r--db/post_migrate/20171101134435_remove_ref_fetched_from_merge_requests.rb14
-rw-r--r--db/schema.rb3
2 files changed, 15 insertions, 2 deletions
diff --git a/db/post_migrate/20171101134435_remove_ref_fetched_from_merge_requests.rb b/db/post_migrate/20171101134435_remove_ref_fetched_from_merge_requests.rb
new file mode 100644
index 00000000000..4e8f495d65d
--- /dev/null
+++ b/db/post_migrate/20171101134435_remove_ref_fetched_from_merge_requests.rb
@@ -0,0 +1,14 @@
+class RemoveRefFetchedFromMergeRequests < ActiveRecord::Migration
+ include Gitlab::Database::MigrationHelpers
+
+ # Set this constant to true if this migration requires downtime.
+ DOWNTIME = false
+
+ # We don't need to cache this anymore: the refs are now created
+ # upon save/update and there is no more use for this flag
+ #
+ # See https://gitlab.com/gitlab-org/gitlab-ce/issues/36061
+ def change
+ remove_column :merge_requests, :ref_fetched, :boolean
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index 80d8ff92d6e..7f1cfed4bb8 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: 20171026082505) do
+ActiveRecord::Schema.define(version: 20171101134435) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"
@@ -970,7 +970,6 @@ ActiveRecord::Schema.define(version: 20171026082505) do
t.datetime "last_edited_at"
t.integer "last_edited_by_id"
t.integer "head_pipeline_id"
- t.boolean "ref_fetched"
t.string "merge_jid"
t.boolean "discussion_locked"
t.integer "latest_merge_request_diff_id"