• Patrick Bajao's avatar
    Schedule MergeRequestCleanupRefsWorker more efficiently · 0080186a
    Patrick Bajao authored
    This converts the MergeRequestCleanupRefsWorker to be a limited
    capacity worker.
    
    The ScheduleMergeRequestCleanupRefsWorker will still be enqueuing
    jobs but it'll be based on capacity. If there's no capacity then
    no new jobs will be enqueued.
    
    For now, we are capping it at 4 jobs at a time. This will be later
    on be configurable.
    
    This is still behind the merge_request_refs_cleanup feature flag
    so we can easily turn it off on production while testing.
    
    Changelog: changed
    0080186a
20210707095545 64 Bytes