Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/uploaders/gitlab_uploader.rb')
-rw-r--r--app/uploaders/gitlab_uploader.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/uploaders/gitlab_uploader.rb b/app/uploaders/gitlab_uploader.rb
index 9758d3c87aa..abe06bd97e1 100644
--- a/app/uploaders/gitlab_uploader.rb
+++ b/app/uploaders/gitlab_uploader.rb
@@ -31,6 +31,14 @@ class GitlabUploader < CarrierWave::Uploader::Base
def absolute_path(upload_record)
File.join(root, upload_record.path)
end
+
+ def version(*args, **kwargs, &block)
+ # CarrierWave uploaded file "versions" are not tracked in the uploads
+ # table. Because of this they won't get replicated to Geo secondaries.
+ # If we ever want to use versions, we need to fix that first. Also see
+ # https://gitlab.com/gitlab-com/gl-infra/scalability/-/issues/1757.
+ raise "using CarrierWave alternate file version is not supported"
+ end
end
storage_options Gitlab.config.uploads