Welcome to mirror list, hosted at ThFree Co, Russian Federation.

20240116133546_add_foreign_key_for_namespace_id_to_member_approvals.rb « migrate « db - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 1d8e42466081badc45e711dc22d48450a6cf32cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

class AddForeignKeyForNamespaceIdToMemberApprovals < Gitlab::Database::Migration[2.2]
  disable_ddl_transaction!
  milestone '16.9'

  def up
    add_concurrent_foreign_key :member_approvals, :namespaces, column: :member_namespace_id
  end

  def down
    with_lock_retries do
      remove_foreign_key :member_approvals, column: :member_namespace_id
    end
  end
end