2018-03-17 18:26:18 +05:30
|
|
|
# rubocop:disable Migration/UpdateLargeTable
|
2017-09-10 17:25:29 +05:30
|
|
|
# rubocop:disable Migration/UpdateColumnInBatches
|
|
|
|
class EnableAutoCancelPendingPipelinesForAll < ActiveRecord::Migration
|
|
|
|
include Gitlab::Database::MigrationHelpers
|
|
|
|
|
|
|
|
disable_ddl_transaction!
|
|
|
|
|
|
|
|
DOWNTIME = false
|
|
|
|
|
|
|
|
def up
|
2018-11-20 20:47:30 +05:30
|
|
|
disable_statement_timeout do
|
|
|
|
update_column_in_batches(:projects, :auto_cancel_pending_pipelines, 1)
|
|
|
|
end
|
2017-09-10 17:25:29 +05:30
|
|
|
end
|
|
|
|
|
|
|
|
def down
|
|
|
|
# Nothing we can do!
|
|
|
|
end
|
|
|
|
end
|