summaryrefslogtreecommitdiff
path: root/config/initializers
diff options
context:
space:
mode:
authorOlaf Tomalka <olaf.tomalka@gmail.com>2016-09-05 22:57:56 +0200
committerOlaf Tomalka <olaf.tomalka@gmail.com>2016-09-07 19:41:25 +0200
commitc0a92cb801528f00d1317b01fd8a94274552c166 (patch)
tree22275ef42f6f897cb684ab67b92124943f703841 /config/initializers
parente25b48ffcf1f7ef31df8d6c3366674e7f5c29893 (diff)
downloadgitlab-ce-c0a92cb801528f00d1317b01fd8a94274552c166.tar.gz
Limited amount of pruned Event rows per run
Old deployments of Gitlab might have a big number of old events to be deleted. Such numbers cause the worker to timeout. I've limited the amount of rows that should be destroyed at once to 10000, and increased how often pruning shall take place to 4 times a day.
Diffstat (limited to 'config/initializers')
-rw-r--r--config/initializers/1_settings.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/initializers/1_settings.rb b/config/initializers/1_settings.rb
index 2fac3e34dc5..195108b921b 100644
--- a/config/initializers/1_settings.rb
+++ b/config/initializers/1_settings.rb
@@ -300,7 +300,7 @@ Settings.cron_jobs['remove_expired_group_links_worker'] ||= Settingslogic.new({}
Settings.cron_jobs['remove_expired_group_links_worker']['cron'] ||= '10 0 * * *'
Settings.cron_jobs['remove_expired_group_links_worker']['job_class'] = 'RemoveExpiredGroupLinksWorker'
Settings.cron_jobs['prune_old_events_worker'] ||= Settingslogic.new({})
-Settings.cron_jobs['prune_old_events_worker']['cron'] ||= '0 0 * * *'
+Settings.cron_jobs['prune_old_events_worker']['cron'] ||= '* */6 * * *'
Settings.cron_jobs['prune_old_events_worker']['job_class'] = 'PruneOldEventsWorker'
#