diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-02 03:09:51 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-07-02 03:09:51 +0300 |
commit | 8584b7d7ce5843465e826fb46b22445a889c6d7c (patch) | |
tree | 909d8a6957917961916c3ef4d5bb167b0893680e /app/services | |
parent | fe25c98fa838d9a6dd08bec9a5ac743560fa2ebd (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services')
-rw-r--r-- | app/services/projects/update_remote_mirror_service.rb | 2 | ||||
-rw-r--r-- | app/services/projects/update_repository_storage_service.rb | 6 |
2 files changed, 6 insertions, 2 deletions
diff --git a/app/services/projects/update_remote_mirror_service.rb b/app/services/projects/update_remote_mirror_service.rb index 5f8ef75a8d7..d6c0d647468 100644 --- a/app/services/projects/update_remote_mirror_service.rb +++ b/app/services/projects/update_remote_mirror_service.rb @@ -29,7 +29,7 @@ module Projects remote_mirror.ensure_remote! # https://gitlab.com/gitlab-org/gitaly/-/issues/2670 - if Feature.disabled?(:gitaly_ruby_remote_branches_ls_remote) + if Feature.disabled?(:gitaly_ruby_remote_branches_ls_remote, default_enabled: true) repository.fetch_remote(remote_mirror.remote_name, ssh_auth: remote_mirror, no_tags: true) end diff --git a/app/services/projects/update_repository_storage_service.rb b/app/services/projects/update_repository_storage_service.rb index 769c779d2dc..7b346c09635 100644 --- a/app/services/projects/update_repository_storage_service.rb +++ b/app/services/projects/update_repository_storage_service.rb @@ -14,7 +14,11 @@ module Projects end def execute - repository_storage_move.start! + repository_storage_move.with_lock do + return ServiceResponse.success unless repository_storage_move.scheduled? # rubocop:disable Cop/AvoidReturnFromBlocks + + repository_storage_move.start! + end raise SameFilesystemError if same_filesystem?(repository.storage, destination_storage_name) |