From d48ee86053acabf4d52effc2a6a2ba714926821d Mon Sep 17 00:00:00 2001 From: Stan Hu Date: Wed, 3 Jul 2019 00:13:00 -0700 Subject: Make Housekeeping button do a full garbage collection Previously the Housekeeping button and API would use the counter of last pushes to determine whether to do a full garbage collection, or whether to do one of the less comprehensive tasks: a full repack, incremental pack, or ref pack. This was confusing behavior, since a project owner might have to click the button dozens of times before a full GC would be initiated. This commit forces a full GC each time this is initiated. Note that the `ExclusiveLease` in `HousekeepingService` prevents users from clicking on the button more than once a day. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/63349 --- app/controllers/projects_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/controllers') diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 12db493978b..9d2f64280a3 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -182,7 +182,7 @@ class ProjectsController < Projects::ApplicationController end def housekeeping - ::Projects::HousekeepingService.new(@project).execute + ::Projects::HousekeepingService.new(@project, :gc).execute redirect_to( project_path(@project), -- cgit v1.2.3