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:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-05-20 03:09:06 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-05-20 03:09:06 +0300
commit7690867e0240248849ae11e4f0c538f60b4c2912 (patch)
tree7cdde324474bf7412274ace8af0235aaf46b4bee
parent8acf72a1d95677e37ca2c3a8bea3e65139443527 (diff)
Add latest changes from gitlab-org/gitlab@master
-rw-r--r--config/feature_flags/development/scan_result_role_action.yml8
-rw-r--r--data/deprecations/16-1-unified-approval-rules.yml29
-rw-r--r--doc/update/deprecations.md20
-rw-r--r--lefthook.yml6
-rw-r--r--lib/gitlab/database/partitioning.rb2
-rw-r--r--locale/gitlab.pot6
-rw-r--r--spec/lib/gitlab/database/partitioning_spec.rb12
7 files changed, 69 insertions, 14 deletions
diff --git a/config/feature_flags/development/scan_result_role_action.yml b/config/feature_flags/development/scan_result_role_action.yml
deleted file mode 100644
index 62129692f80..00000000000
--- a/config/feature_flags/development/scan_result_role_action.yml
+++ /dev/null
@@ -1,8 +0,0 @@
----
-name: scan_result_role_action
-introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/101464
-rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/377866
-milestone: '15.6'
-type: development
-group: group::security policies
-default_enabled: true
diff --git a/data/deprecations/16-1-unified-approval-rules.yml b/data/deprecations/16-1-unified-approval-rules.yml
new file mode 100644
index 00000000000..8622ed86d5f
--- /dev/null
+++ b/data/deprecations/16-1-unified-approval-rules.yml
@@ -0,0 +1,29 @@
+- title: "Unified approval rules are deprecated" # (required) Clearly explain the change, or planned change. For example, "The `confidential` field for a `Note` is deprecated" or "CI/CD job names will be limited to 250 characters."
+ announcement_milestone: "16.1" # (required) The milestone when this feature was first announced as deprecated.
+ removal_milestone: "17.0" # (required) The milestone when this feature is planned to be removed
+ breaking_change: true # (required) Change to false if this is not a breaking change.
+ reporter: nagyv-gitlab # (required) GitLab username of the person reporting the change
+ stage: deploy # (required) String value of the stage that the feature was created in. e.g., Growth
+ issue_url: https://gitlab.com/groups/gitlab-org/-/epics/9662 # (required) Link to the deprecation issue in GitLab
+ body: | # (required) Do not modify this line, instead modify the lines below.
+ Unified approval rules are deprecated in favor of multiple approval rules, which provide more flexibility.
+ You might not be able to migrate your Unified approval rules to multiple approval rules without breaking changes.
+ To help you migrate manually, we introduced migration documentation. If you don't migrate manually before unified approval
+ rules are removed, GitLab will automatically migrate your settings.
+
+ In GitLab 15.11, UI support for unified approval rules was removed.
+ You can still access unified approval rules with the API.
+#
+# OPTIONAL END OF SUPPORT FIELDS
+#
+# If an End of Support period applies, the announcement should be shared with GitLab Support
+# in the `#spt_managers` channel in Slack, and mention `@gitlab-com/support` in this MR.
+#
+ end_of_support_milestone: # (optional) Use "XX.YY" format. The milestone when support for this feature will end.
+ #
+ # OTHER OPTIONAL FIELDS
+ #
+ tiers: [Premium, Ultimate] # (optional - may be required in the future) An array of tiers that the feature is available in currently. e.g., [Free, Silver, Gold, Core, Premium, Ultimate]
+ documentation_url: https://docs.gitlab.com/ee/ci/environments/deployment_approvals.html # (optional) This is a link to the current documentation page
+ image_url: # (optional) This is a link to a thumbnail image depicting the feature
+ video_url: # (optional) Use the youtube thumbnail URL with the structure of https://img.youtube.com/vi/UNIQUEID/hqdefault.jpg
diff --git a/doc/update/deprecations.md b/doc/update/deprecations.md
index 4ba4a0137bf..029a03ca67d 100644
--- a/doc/update/deprecations.md
+++ b/doc/update/deprecations.md
@@ -631,6 +631,26 @@ In some cases, like when a downstream pipeline had the `passed with warnings` st
<div class="deprecation breaking-change" data-milestone="17.0">
+### Unified approval rules are deprecated
+
+<div class="deprecation-notes">
+- Announced in: GitLab <span class="milestone">16.1</span>
+- This is a [breaking change](https://docs.gitlab.com/ee/development/deprecation_guidelines/).
+- To discuss this change or learn more, see the [deprecation issue](https://gitlab.com/groups/gitlab-org/-/epics/9662).
+</div>
+
+Unified approval rules are deprecated in favor of multiple approval rules, which provide more flexibility.
+You might not be able to migrate your Unified approval rules to multiple approval rules without breaking changes.
+To help you migrate manually, we introduced migration documentation. If you don't migrate manually before unified approval
+rules are removed, GitLab will automatically migrate your settings.
+
+In GitLab 15.11, UI support for unified approval rules was removed.
+You can still access unified approval rules with the API.
+
+</div>
+
+<div class="deprecation breaking-change" data-milestone="17.0">
+
### `runnerRegistrationToken` parameter for GitLab Runner Helm Chart
<div class="deprecation-notes">
diff --git a/lefthook.yml b/lefthook.yml
index 580a52db330..03a4903117f 100644
--- a/lefthook.yml
+++ b/lefthook.yml
@@ -91,6 +91,12 @@ pre-push:
files: git diff --name-only --diff-filter=d $(git merge-base origin/master HEAD)..HEAD
glob: 'db/structure.sql'
run: scripts/validate_schema_changes
+ static-verification:
+ skip: true # This is disabled by default. You can enable this check by adding skip: false in lefhook-local.yml https://github.com/evilmartians/lefthook/blob/master/docs/configuration.md#skip
+ tags: backend
+ files: git diff --name-only --diff-filter=d $(git merge-base origin/master HEAD)..HEAD
+ glob: '*.{rb}'
+ run: bundle exec rake lint:static_verification
scripts:
"merge_conflicts":
diff --git a/lib/gitlab/database/partitioning.rb b/lib/gitlab/database/partitioning.rb
index 7222f148b3f..5d507342ee0 100644
--- a/lib/gitlab/database/partitioning.rb
+++ b/lib/gitlab/database/partitioning.rb
@@ -60,6 +60,8 @@ module Gitlab
end
def drop_detached_partitions
+ return unless Feature.enabled?(:partition_manager_sync_partitions, type: :ops)
+
Gitlab::AppLogger.info(message: 'Dropping detached postgres partitions')
Gitlab::Database::EachDatabase.each_database_connection do
diff --git a/locale/gitlab.pot b/locale/gitlab.pot
index d06749ed65f..c021dc5dd46 100644
--- a/locale/gitlab.pot
+++ b/locale/gitlab.pot
@@ -39805,9 +39805,6 @@ msgstr ""
msgid "ScanResultPolicy|%{count} licenses"
msgstr ""
-msgid "ScanResultPolicy|%{thenLabelStart}Then%{thenLabelEnd} Require approval from %{approvalsRequired} of the following approvers:"
-msgstr ""
-
msgid "ScanResultPolicy|Add new criteria"
msgstr ""
@@ -39856,9 +39853,6 @@ msgstr ""
msgid "ScanResultPolicy|When %{scanners} find scanner specified conditions in an open merge request targeting the %{branches} and match %{boldDescription} of the following criteria"
msgstr ""
-msgid "ScanResultPolicy|add an approver"
-msgstr ""
-
msgid "ScanResultPolicy|except"
msgstr ""
diff --git a/spec/lib/gitlab/database/partitioning_spec.rb b/spec/lib/gitlab/database/partitioning_spec.rb
index 9df238a0024..e654cb65452 100644
--- a/spec/lib/gitlab/database/partitioning_spec.rb
+++ b/spec/lib/gitlab/database/partitioning_spec.rb
@@ -247,6 +247,18 @@ RSpec.describe Gitlab::Database::Partitioning, feature_category: :database do
.and change { table_exists?(table_names.last) }.from(true).to(false)
end
+ context 'when the feature flag is disabled' do
+ before do
+ stub_feature_flags(partition_manager_sync_partitions: false)
+ end
+
+ it 'does not call the DetachedPartitionDropper' do
+ expect(Gitlab::Database::Partitioning::DetachedPartitionDropper).not_to receive(:new)
+
+ described_class.drop_detached_partitions
+ end
+ end
+
def table_exists?(table_name)
table_oid(table_name).present?
end