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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
533a6fef
Commit
533a6fef
authored
Oct 06, 2018
by
Jeremy Watson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated code comments for clarity based on 2 years
parent
b0ae67a4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
app/workers/prune_old_events_worker.rb
app/workers/prune_old_events_worker.rb
+2
-3
No files found.
app/workers/prune_old_events_worker.rb
View file @
533a6fef
...
...
@@ -6,9 +6,8 @@ class PruneOldEventsWorker
# rubocop: disable CodeReuse/ActiveRecord
def
perform
# Contribution calendar shows maximum 12 months of events.
# Double nested query is used because MySQL doesn't allow DELETE subqueries
# on the same table.
# Contribution calendar shows maximum 12 months of events, we retain 2 years for data integrity.
# Double nested query is used because MySQL doesn't allow DELETE subqueries on the same table.
Event
.
unscoped
.
where
(
'(id IN (SELECT id FROM (?) ids_to_remove))'
,
Event
.
unscoped
.
where
(
...
...
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