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

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

class AddThrottleDeprecatedApiColumns < Gitlab::Database::Migration[1.0]
  def change
    add_column :application_settings, :throttle_unauthenticated_deprecated_api_requests_per_period, :integer, default: 3600, null: false
    add_column :application_settings, :throttle_unauthenticated_deprecated_api_period_in_seconds, :integer, default: 3600, null: false
    add_column :application_settings, :throttle_unauthenticated_deprecated_api_enabled, :boolean, default: false, null: false

    add_column :application_settings, :throttle_authenticated_deprecated_api_requests_per_period, :integer, default: 3600, null: false
    add_column :application_settings, :throttle_authenticated_deprecated_api_period_in_seconds, :integer, default: 1800, null: false
    add_column :application_settings, :throttle_authenticated_deprecated_api_enabled, :boolean, default: false, null: false
  end
end