diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-08 15:08:54 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-08 15:08:54 +0300 |
commit | 473b876fe3d7e0b36eb6268cc44a4fe0d94f4422 (patch) | |
tree | 2f6d5f2ecad53015024b6b1509896f5933c5c3e6 /app/services/auto_merge | |
parent | dca8df0c90d8727d69b3501b15b481546897f3cd (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services/auto_merge')
-rw-r--r-- | app/services/auto_merge/merge_when_pipeline_succeeds_service.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/app/services/auto_merge/merge_when_pipeline_succeeds_service.rb b/app/services/auto_merge/merge_when_pipeline_succeeds_service.rb index d18f2935d92..2bbb8f925a4 100644 --- a/app/services/auto_merge/merge_when_pipeline_succeeds_service.rb +++ b/app/services/auto_merge/merge_when_pipeline_succeeds_service.rb @@ -11,9 +11,14 @@ module AutoMerge end def process(merge_request) + logger.info("Processing Automerge") return unless merge_request.actual_head_pipeline_success? + + logger.info("Pipeline Success") return unless merge_request.mergeable? + logger.info("Merge request mergeable") + merge_request.merge_async(merge_request.merge_user_id, merge_request.merge_params) end @@ -40,5 +45,9 @@ module AutoMerge def notify(merge_request) notification_service.async.merge_when_pipeline_succeeds(merge_request, current_user) if merge_request.saved_change_to_auto_merge_enabled? end + + def logger + @logger ||= Gitlab::AppLogger + end end end |