Commit 0b5407cc authored by Stan Hu's avatar Stan Hu

Set feature flag lfs_auto_link_fork_source to true by default

This sets the feature flag introduced in
https://gitlab.com/gitlab-org/gitlab/-/merge_requests/75972 by
default. This has been running in production for over a week
(https://gitlab.com/gitlab-org/gitlab/-/issues/348243).

Previously LFS uploads would always have to be reuploaded to a fork even
if the parent already had received the LFS file, but this is
unnecessary, wasting time and bandwidth. Consider this sequence of
events:

1. Push LFS file `test.bin` to project A.
2. Fork project A to project B.
3. Push LFS file `test2.bin` to project A.
4. Push to project B.

When 4 happens, GitLab should be smart enough to realize that if the
user has access to the parent project, then we should be able to link
the LFS files in A without requesting a reupload of the file.

Relates to https://gitlab.com/gitlab-org/gitlab/-/issues/348243

Changelog: changed
parent 69a452c8
......@@ -155,7 +155,7 @@ module Repositories
end
def should_auto_link?
return false unless Feature.enabled?(:lfs_auto_link_fork_source, project)
return false unless Feature.enabled?(:lfs_auto_link_fork_source, project, default_enabled: :yaml)
return false unless project.forked?
# Sanity check in case for some reason the user doesn't have access to the parent
......
......@@ -5,4 +5,4 @@ rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/348243
milestone: '14.6'
type: development
group: group::source code
default_enabled: false
default_enabled: true
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment