diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-07-08 03:09:36 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-07-08 03:09:36 +0300 |
commit | 5487465d35110ef72c2e7cea7ef031c3ddf4dcbc (patch) | |
tree | 8f0b93358623fd03a912c4e6d373d1bc8aed6949 /db | |
parent | 2f8483621ea55d217f8ee92d22ba2ce0c250d0b0 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'db')
-rw-r--r-- | db/post_migrate/20220706115138_create_async_index_on_security_findings.rb | 22 | ||||
-rw-r--r-- | db/schema_migrations/20220706115138 | 1 |
2 files changed, 23 insertions, 0 deletions
diff --git a/db/post_migrate/20220706115138_create_async_index_on_security_findings.rb b/db/post_migrate/20220706115138_create_async_index_on_security_findings.rb new file mode 100644 index 00000000000..30baa1af91c --- /dev/null +++ b/db/post_migrate/20220706115138_create_async_index_on_security_findings.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +class CreateAsyncIndexOnSecurityFindings < Gitlab::Database::Migration[2.0] + INDEX_NAME = 'index_on_security_findings_uuid_and_id_order_desc' + + def up + prepare_async_index( + :security_findings, + %i[uuid id], + order: { id: :desc }, + name: INDEX_NAME + ) + end + + def down + unprepare_async_index( + :security_findings, + %i[uuid id], + name: INDEX_NAME + ) + end +end diff --git a/db/schema_migrations/20220706115138 b/db/schema_migrations/20220706115138 new file mode 100644 index 00000000000..0c139470b47 --- /dev/null +++ b/db/schema_migrations/20220706115138 @@ -0,0 +1 @@ +c0c4a18cb711e0288bf1d385e06151e0e329dc40d4e9cd51e6437fe73d6bfc21
\ No newline at end of file |