diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-17 15:08:36 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-17 15:08:36 +0000 |
commit | c61d90dbfa0a7cb58b758ed07a9d0b5406beb61e (patch) | |
tree | 5c29d476a605417c370997caf3dabe8e8270b8be /app/workers | |
parent | a89912871cb169249d3ddc2ed59326d47ecdae82 (diff) | |
download | gitlab-ce-c61d90dbfa0a7cb58b758ed07a9d0b5406beb61e.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/workers')
-rw-r--r-- | app/workers/all_queues.yml | 8 | ||||
-rw-r--r-- | app/workers/authorized_project_update/project_group_link_create_worker.rb | 21 |
2 files changed, 29 insertions, 0 deletions
diff --git a/app/workers/all_queues.yml b/app/workers/all_queues.yml index 0699be0f4cb..3a25ce2e870 100644 --- a/app/workers/all_queues.yml +++ b/app/workers/all_queues.yml @@ -11,6 +11,14 @@ :weight: 1 :idempotent: true :tags: [] +- :name: authorized_project_update:authorized_project_update_project_group_link_create + :feature_category: :authentication_and_authorization + :has_external_dependencies: + :urgency: :low + :resource_boundary: :unknown + :weight: 1 + :idempotent: true + :tags: [] - :name: authorized_project_update:authorized_project_update_user_refresh_with_low_urgency :feature_category: :authentication_and_authorization :has_external_dependencies: diff --git a/app/workers/authorized_project_update/project_group_link_create_worker.rb b/app/workers/authorized_project_update/project_group_link_create_worker.rb new file mode 100644 index 00000000000..5fb59efaacb --- /dev/null +++ b/app/workers/authorized_project_update/project_group_link_create_worker.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +module AuthorizedProjectUpdate + class ProjectGroupLinkCreateWorker + include ApplicationWorker + + feature_category :authentication_and_authorization + urgency :low + queue_namespace :authorized_project_update + + idempotent! + + def perform(project_id, group_id) + project = Project.find(project_id) + group = Group.find(group_id) + + AuthorizedProjectUpdate::ProjectGroupLinkCreateService.new(project, group) + .execute + end + end +end |