summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-02-07 13:09:53 +0100
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-02-07 13:09:53 +0100
commit394c1c65883883d5ac8bcbeecd9fe05b1d3fd87b (patch)
tree866e3f23cddd8863b64b04fc28f58417b85da744
parent2cce501f452e84d9fe8c27bd0291e4984c12bc4c (diff)
downloadgitlab-ce-394c1c65883883d5ac8bcbeecd9fe05b1d3fd87b.tar.gz
Disable statement timeout when removing redundant stages
-rw-r--r--db/post_migrate/20180119121225_remove_redundant_pipeline_stages.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/db/post_migrate/20180119121225_remove_redundant_pipeline_stages.rb b/db/post_migrate/20180119121225_remove_redundant_pipeline_stages.rb
index 1962c16d84a..61ea85eb2a7 100644
--- a/db/post_migrate/20180119121225_remove_redundant_pipeline_stages.rb
+++ b/db/post_migrate/20180119121225_remove_redundant_pipeline_stages.rb
@@ -38,6 +38,8 @@ class RemoveRedundantPipelineStages < ActiveRecord::Migration
end
def remove_redundant_pipeline_stages!
+ disable_statement_timeout
+
redundant_stages_ids = <<~SQL
SELECT id FROM ci_stages WHERE (pipeline_id, name) IN (
SELECT pipeline_id, name FROM ci_stages