提交 57ac0bc8 编写于 作者: G GitLab Bot

Add latest changes from gitlab-org/gitlab@master

上级 7942fe67
......@@ -17,7 +17,6 @@ class Admin::RunnersController < Admin::ApplicationController
def update
if Ci::UpdateRunnerService.new(@runner).update(runner_params)
respond_to do |format|
format.js
format.html { redirect_to admin_runner_path(@runner) }
end
else
......
......@@ -38,8 +38,6 @@ module AutoMerge
private
def notify(merge_request)
return unless Feature.enabled?(:mwps_notification, project)
notification_service.async.merge_when_pipeline_succeeds(merge_request, current_user) if merge_request.saved_change_to_auto_merge_enabled?
end
end
......
......@@ -126,8 +126,7 @@ module Projects
def migrate_to_hashed_storage?
Gitlab::CurrentSettings.hashed_storage_enabled? &&
project.storage_upgradable? &&
Feature.disabled?(:skip_hashed_storage_upgrade)
project.storage_upgradable?
end
def send_move_instructions?
......
:plain
$("#runner_#{@runner.id}").replaceWith("#{escape_javascript(render(@runner))}")
---
title: Remove skip_hased_storage_upgrade feature flag
merge_request: 29364
author: Lee Tickett
type: other
---
title: Send notification when merge request is set to merge when pipeline succeeds
merge_request: 39297
author: Ravishankar Gnanaprakasam
type: added
......@@ -995,8 +995,12 @@ information, see the [strong consistency epic](https://gitlab.com/groups/gitlab-
To enable strong consistency:
- In GitLab 13.3 and later, reference transactions are enabled by default with
a primary-wins strategy. This strategy causes all transactions to succeed for
- In GitLab 13.4 and later, the strong consistency voting strategy has been
improved. Instead of requiring all nodes to agree, only the primary and half
of the secondaries need to agree. To enable this strategy, disable the
`:gitaly_reference_transactions_primary_wins` feature flag.
- In GitLab 13.3, reference transactions are enabled by default with a
primary-wins strategy. This strategy causes all transactions to succeed for
the primary and thus does not ensure strong consistency. To enable strong
consistency, disable the `:gitaly_reference_transactions_primary_wins`
feature flag.
......
......@@ -212,11 +212,8 @@ Find the current permissions on the Value Stream Analytics dashboard, as describ
### Issue Board permissions
Developers and users with higher permission level can use all
the functionality of the Issue Board, that is create/delete lists
and drag issues around. Read through the
[documentation on Issue Boards permissions](project/issue_board.md#permissions)
to learn more.
Find the current permissions for interacting with the Issue Board feature in the
[Issue Boards permissions page](project/issue_board.md#permissions).
### File Locking permissions **(PREMIUM)**
......
......@@ -184,6 +184,7 @@ To minimize the number of notifications that do not require any action, from [Gi
| Close merge request | |
| Reopen merge request | |
| Merge merge request | |
| Merge when pipeline succeeds ([Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/211961) in GitLab 13.4) | |
| Change milestone merge request | Subscribers, participants mentioned, and Custom notification level with this event selected |
| Remove milestone merge request | Subscribers, participants mentioned, and Custom notification level with this event selected |
| New comment | The above, plus anyone mentioned by `@username` in the comment, with notification level "Mention" or higher |
......
......@@ -568,25 +568,42 @@ RSpec.describe ProjectsController do
end
context 'when only renaming a project path' do
it "sets the repository to the right path after a rename" do
it "doesnt change the disk_path when using hashed storage" do
skip unless project.hashed_storage?(:repository)
hashed_storage_path = ::Storage::Hashed.new(project).disk_path
original_repository_path = Gitlab::GitalyClient::StorageSettings.allow_disk_access do
project.repository.path
end
expect { update_project path: 'renamed_path' }
.to change { project.reload.path }
expect { update_project path: 'renamed_path' }.to change { project.reload.path }
expect(project.path).to include 'renamed_path'
assign_repository_path = Gitlab::GitalyClient::StorageSettings.allow_disk_access do
assigns(:repository).path
end
if project.hashed_storage?(:repository)
expect(assign_repository_path).to eq(original_repository_path)
else
expect(assign_repository_path).to include(project.path)
expect(original_repository_path).to include(hashed_storage_path)
expect(assign_repository_path).to include(hashed_storage_path)
end
it "upgrades and move project to hashed storage when project was originally legacy" do
skip if project.hashed_storage?(:repository)
hashed_storage_path = Storage::Hashed.new(project).disk_path
original_repository_path = Gitlab::GitalyClient::StorageSettings.allow_disk_access do
project.repository.path
end
expect { update_project path: 'renamed_path' }.to change { project.reload.path }
expect(project.path).to include 'renamed_path'
assign_repository_path = Gitlab::GitalyClient::StorageSettings.allow_disk_access do
assigns(:repository).path
end
expect(original_repository_path).not_to include(hashed_storage_path)
expect(assign_repository_path).to include(hashed_storage_path)
expect(response).to have_gitlab_http_status(:found)
end
end
......
......@@ -91,18 +91,6 @@ RSpec.describe AutoMerge::MergeWhenPipelineSucceedsService do
end
end
context 'without feature enabled' do
it 'does not send notification' do
stub_feature_flags(mwps_notification: false)
allow(merge_request)
.to receive_messages(head_pipeline: pipeline, actual_head_pipeline: pipeline)
expect(MailScheduler::NotificationServiceWorker).not_to receive(:perform_async)
service.execute(merge_request)
end
end
context 'already approved' do
let(:service) { described_class.new(project, user, should_remove_source_branch: true) }
let(:build) { create(:ci_build, ref: mr_merge_if_green_enabled.source_branch) }
......
......@@ -22,7 +22,6 @@ RSpec.describe Projects::AfterRenameService do
# call. This makes testing a bit easier.
allow(project).to receive(:gitlab_shell).and_return(gitlab_shell)
stub_feature_flags(skip_hashed_storage_upgrade: false)
stub_application_setting(hashed_storage_enabled: false)
end
......@@ -151,7 +150,6 @@ RSpec.describe Projects::AfterRenameService do
# call. This makes testing a bit easier.
allow(project).to receive(:gitlab_shell).and_return(gitlab_shell)
stub_feature_flags(skip_hashed_storage_upgrade: false)
stub_application_setting(hashed_storage_enabled: true)
end
......
......@@ -325,20 +325,9 @@ RSpec.describe Projects::UpdateService do
expect(project.errors.messages[:base]).to include('There is already a repository with that name on disk')
end
it 'renames the project without upgrading it' do
result = update_project(project, admin, path: 'new-path')
expect(result).not_to include(status: :error)
expect(project).to be_valid
expect(project.errors).to be_empty
expect(project.disk_path).to include('new-path')
expect(project.reload.hashed_storage?(:repository)).to be_falsey
end
context 'when hashed storage is enabled' do
before do
stub_application_setting(hashed_storage_enabled: true)
stub_feature_flags(skip_hashed_storage_upgrade: false)
end
it 'migrates project to a hashed storage instead of renaming the repo to another legacy name' do
......@@ -349,22 +338,6 @@ RSpec.describe Projects::UpdateService do
expect(project.errors).to be_empty
expect(project.reload.hashed_storage?(:repository)).to be_truthy
end
context 'when skip_hashed_storage_upgrade feature flag is enabled' do
before do
stub_feature_flags(skip_hashed_storage_upgrade: true)
end
it 'renames the project without upgrading it' do
result = update_project(project, admin, path: 'new-path')
expect(result).not_to include(status: :error)
expect(project).to be_valid
expect(project.errors).to be_empty
expect(project.disk_path).to include('new-path')
expect(project.reload.hashed_storage?(:repository)).to be_falsey
end
end
end
end
......
......@@ -848,10 +848,10 @@
resolved "https://registry.yarnpkg.com/@gitlab/svgs/-/svgs-1.161.0.tgz#661e8d19862dfba0e4c558e2eb6d64b402c1453e"
integrity sha512-qsbboEICn08ZoEoAX/TuYygsFaXlzsCY+CfmdOzqvJbOdfHhVXmrJBxd2hP2qqjTZm2PkbRRmn+03+ce1jvatQ==
"@gitlab/ui@20.12.0":
version "20.12.0"
resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-20.12.0.tgz#694cfe9793b8dd9f24e16373321bf25bd9b4f9c0"
integrity sha512-5QgWFjOoWsTbMq7LqE7w1hmgSE4N8Z08vDmAg+HNsn50mtPQeIRKofYmyvfXCpRoL7e0a/HHfLU0HqctZLILGQ==
"@gitlab/ui@20.12.1":
version "20.12.1"
resolved "https://registry.yarnpkg.com/@gitlab/ui/-/ui-20.12.1.tgz#7ff01a52c777168feac764f94a9d9e024c157b02"
integrity sha512-X7ICu/gVK48ok3SQyH9bOE5zaVGIb8nN0Oz+pKhTz2PoZz7e3Js5ZSQFrb4UQmkQGYIOZiSj+NCeKlpmzPYk2g==
dependencies:
"@babel/standalone" "^7.0.0"
"@gitlab/vue-toasted" "^1.3.0"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册