Skip to content

Disable workhorse archive cache by default

Gerard Hickey requested to merge 2204-disable-workhorse-cache into master

In a cloud native environment there is not as shared filesystem between the workhorse, sidekiq and task-runner pods and as a result each instance of workhorse will maintain an individual cache of downloaded archive files. The bigger issue in a cloud native environment is that the archive files are not cleaned up by the sidekiq instance so the filesystems on the workhorse intances continue to increase and are not pruned.

The original plan was to set the workhorse_archive_cache_disabled feature flag in the custom-instance-setup script that run as part of the migration job, but this had issues with workhorse being able to serve static content. Please see gitlab-org/build/CNG!521 (closed) for more information.

Also as noted in gitlab-org/build/CNG!521 (comment 404094126), the location for the archive cache is located in /srv/gitlab/shared/cache/archive which is different than the location under Omnibus. Testing become pretty straight forward by creating a repo, download the archive of the repo (zip, tar.gz, etc) and then checking the workhorse pods for content at this location. Note: it may be beneficial to limit the number of workhorse pods to 1 for testing.

Closes #2204 (closed)

Edited by Gerard Hickey

Merge request reports