Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
178c21b0
Commit
178c21b0
authored
Dec 11, 2020
by
Marc Shaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Switch diff_check_with_paths_changed_rpc_flag flag to default true
parent
628f756f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
4 deletions
+9
-4
changelogs/unreleased/switch_diff_check_with_paths_changed_rpc_flag_on.yml
...ased/switch_diff_check_with_paths_changed_rpc_flag_on.yml
+5
-0
config/feature_flags/development/diff_check_with_paths_changed_rpc.yml
...e_flags/development/diff_check_with_paths_changed_rpc.yml
+1
-1
ee/lib/ee/gitlab/checks/diff_check.rb
ee/lib/ee/gitlab/checks/diff_check.rb
+2
-2
lib/gitlab/checks/diff_check.rb
lib/gitlab/checks/diff_check.rb
+1
-1
No files found.
changelogs/unreleased/switch_diff_check_with_paths_changed_rpc_flag_on.yml
0 → 100644
View file @
178c21b0
---
title
:
Improve the performance of the diff change access check
merge_request
:
49803
author
:
type
:
performance
config/feature_flags/development/diff_check_with_paths_changed_rpc.yml
View file @
178c21b0
...
...
@@ -5,4 +5,4 @@ rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/288827
milestone
:
'
13.7'
type
:
development
group
:
group::code review
default_enabled
:
fals
e
default_enabled
:
tru
e
ee/lib/ee/gitlab/checks/diff_check.rb
View file @
178c21b0
...
...
@@ -58,7 +58,7 @@ module EE
def
path_locks_validation
lambda
do
|
diff
|
path
=
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
)
path
=
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
,
default_enabled:
true
)
diff
.
path
else
if
diff
.
renamed_file?
...
...
@@ -82,7 +82,7 @@ module EE
def
file_name_validation
lambda
do
|
diff
|
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
)
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
,
default_enabled:
true
)
if
new_file?
(
diff
)
&&
denylisted_regex
=
push_rule
.
filename_denylisted?
(
diff
.
path
)
return
unless
denylisted_regex
.
present?
...
...
lib/gitlab/checks/diff_check.rb
View file @
178c21b0
...
...
@@ -17,7 +17,7 @@ module Gitlab
file_paths
=
[]
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
)
if
::
Feature
.
enabled?
(
:diff_check_with_paths_changed_rpc
,
project
,
default_enabled:
true
)
paths
=
project
.
repository
.
find_changed_paths
(
commits
.
map
(
&
:sha
))
paths
.
each
do
|
path
|
file_paths
.
concat
([
path
.
path
])
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment