Merge branch 'zj-fork-opt-out' into 'master'

Forking repositories is handled by Gitaly by default

See merge request gitlab-org/gitlab-ce!18679
This commit is contained in:
Douwe Maan 2018-05-03 08:12:04 +00:00
commit 639cf5617f
2 changed files with 7 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
title: Gitaly handles repository forks by default
merge_request:
author:
type: other

View file

@ -63,7 +63,8 @@ module Gitlab
end
def fork_repository(new_shard_name, new_repository_relative_path)
Gitlab::GitalyClient.migrate(:fork_repository) do |is_enabled|
Gitlab::GitalyClient.migrate(:fork_repository,
status: Gitlab::GitalyClient::MigrationStatus::OPT_OUT) do |is_enabled|
if is_enabled
gitaly_fork_repository(new_shard_name, new_repository_relative_path)
else