Skip to content

Add sidekiq worker for scheduled merge

Niklas van Schrick requested to merge 14380-scheduled-merge/sidekiq-worker into master
  • Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA

What does this MR do and why?

Related to #14380

This MR is part of a multi-MR feature:

Changes MR
New attribute on MRs !165092 (merged)
Mergeability check !165099 (merged)
Sidekiq worker 👈
Frontend & Controller changes !165250

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

How to set up and validate locally

  1. Ensure you have a runner set up (you need to be able to get a successful pipeline)
  2. Create (or use an existing) project
  3. Have a pipeline in the project. Something simple as this is enough:
    job:
      script:
        - exit 0
  4. Make any change and open a MR
  5. In the rails console, execute MergeRequests::MergeSchedule.create(merge_request: MergeRequest.last, merge_after: 2.minutes.from_now)
  6. Reload the MR page and see that one merge check fails (the widget won't show the failing check as that is getting added in the next MR of the chain)
  7. Set the MR to auto-merge
  8. Observe that the MR will get auto-merged after the merge_after time you set earlier
Edited by Niklas van Schrick

Merge request reports

Loading