diff options
author | Robert Speicher <rspeicher@gmail.com> | 2021-01-20 22:34:23 +0300 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2021-01-20 22:34:23 +0300 |
commit | 6438df3a1e0fb944485cebf07976160184697d72 (patch) | |
tree | 00b09bfd170e77ae9391b1a2f5a93ef6839f2597 /app/models/audit_event.rb | |
parent | 42bcd54d971da7ef2854b896a7b34f4ef8601067 (diff) |
Add latest changes from gitlab-org/gitlab@13-8-stable-eev13.8.0-rc42
Diffstat (limited to 'app/models/audit_event.rb')
-rw-r--r-- | app/models/audit_event.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/audit_event.rb b/app/models/audit_event.rb index a4d991b040c..d1c0bb11dc8 100644 --- a/app/models/audit_event.rb +++ b/app/models/audit_event.rb @@ -4,6 +4,7 @@ class AuditEvent < ApplicationRecord include CreatedAtFilterable include BulkInsertSafe include EachBatch + include PartitionedTable PARALLEL_PERSISTENCE_COLUMNS = [ :author_name, @@ -15,6 +16,8 @@ class AuditEvent < ApplicationRecord self.primary_key = :id + partitioned_by :created_at, strategy: :monthly + serialize :details, Hash # rubocop:disable Cop/ActiveRecordSerialize belongs_to :user, foreign_key: :author_id |