Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
3c1fb3e4
Commit
3c1fb3e4
authored
Dec 13, 2021
by
Lucas Charles
Committed by
Adam Hegyi
Dec 13, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reschedule Recalculate Finding signatures BG migration
parent
d0307a67
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
0 deletions
+28
-0
db/post_migrate/20211208171402_reschedule_recalculate_vulnerability_finding_signatures_for_findings.rb
...alculate_vulnerability_finding_signatures_for_findings.rb
+27
-0
db/schema_migrations/20211208171402
db/schema_migrations/20211208171402
+1
-0
No files found.
db/post_migrate/20211208171402_reschedule_recalculate_vulnerability_finding_signatures_for_findings.rb
0 → 100644
View file @
3c1fb3e4
# frozen_string_literal: true
class
RescheduleRecalculateVulnerabilityFindingSignaturesForFindings
<
Gitlab
::
Database
::
Migration
[
1.0
]
MIGRATION
=
'RecalculateVulnerabilityFindingSignaturesForFindings'
BATCH_SIZE
=
1_000
DELAY_INTERVAL
=
2
.
minutes
disable_ddl_transaction!
# Due to production incident previous migration was orphaned and must be rescheduled,
# See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/72919#note_741188600
def
up
return
unless
Gitlab
.
ee?
delete_queued_jobs
(
MIGRATION
)
requeue_background_migration_jobs_by_range_at_intervals
(
MIGRATION
,
DELAY_INTERVAL
,
batch_size:
BATCH_SIZE
)
end
def
down
# no-op
end
end
db/schema_migrations/20211208171402
0 → 100644
View file @
3c1fb3e4
09a9e7fc042aab19bf768a79401f33b6e7408acff303fc0ee68360dfd7605101
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment