diff options
Diffstat (limited to 'config/initializers/postgres_partitioning.rb')
-rw-r--r-- | config/initializers/postgres_partitioning.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/config/initializers/postgres_partitioning.rb b/config/initializers/postgres_partitioning.rb index f99333f7c82..4de6e706f16 100644 --- a/config/initializers/postgres_partitioning.rb +++ b/config/initializers/postgres_partitioning.rb @@ -3,7 +3,8 @@ Gitlab::Database::Partitioning.register_models([ AuditEvent, WebHookLog, - LooseForeignKeys::DeletedRecord + LooseForeignKeys::DeletedRecord, + Gitlab::Database::BackgroundMigration::BatchedJobTransitionLog ]) if Gitlab.ee? @@ -14,10 +15,12 @@ if Gitlab.ee? else Gitlab::Database::Partitioning.register_tables([ { + limit_connection_names: %i[main], table_name: 'incident_management_pending_alert_escalations', partitioned_column: :process_at, strategy: :monthly }, { + limit_connection_names: %i[main], table_name: 'incident_management_pending_issue_escalations', partitioned_column: :process_at, strategy: :monthly } @@ -28,8 +31,9 @@ end unless Gitlab.jh? Gitlab::Database::Partitioning.register_tables([ # This should be synchronized with the following model: - # https://gitlab.com/gitlab-jh/gitlab/-/blob/main-jh/jh/app/models/phone/verification_code.rb + # https://jihulab.com/gitlab-cn/gitlab/-/blob/main-jh/jh/app/models/phone/verification_code.rb { + limit_connection_names: %i[main], table_name: 'verification_codes', partitioned_column: :created_at, strategy: :monthly } |