Move `Chain::Limit::Size` from ee to core
-
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?
Fix #287669
Limits related to pipeline creation such as
Chain::Limit::Size
,Chain::Limit::Activity
andChain::Limit::JobActivity
are defined on GitLab EE codebase but not in Core...
After checking, only Chain::Limit::Size
requires migration:
-
Chain::Limit::Size
: Addressed by this MR -
Chain::Limit::Activity
: According to f30fa989,Activity
is deprecated and removed. Nothing to do here. -
Chain::Limit::JobActivity
: According to !100184 (3e4785c8),JobActivity
was deprecated in favor ofActiveJob
, which is already in core. Nothing to do here.
How to review this MR
Please consider review commits separately.
The first commit addresses #287669. The following 7 commits fix Rubocop violations for the moved files, one rule at a time. That's because modifying the .rubocop_todo
to ignore the new file paths doesn't seem to be easier.
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
Should be unchanged. Please see the "How to set up and validate locally" section below
Before (tested on master da55fe1) |
After | |
---|---|---|
foss | Can create pipeline successfully |
Blocked by The number of jobs has exceeded the limit of 2.
|
ee |
Blocked by The number of jobs has exceeded the limit of 2.
|
Blocked by The number of jobs has exceeded the limit of 2. (unchanged) |
How to set up and validate locally
- Visit
/admin/application_settings/ci_cd#js-ci-cd-settings
and setMaximum number of jobs in a single pipeline
to2
- Create a new project, with a new pipeline with 3 jobs. (Just remove one job from the default Pipeline Editor template)
- If it's CE with master code, the pipeline should be created successfully. To simulate CE, follow Simulate a CE instance with a licensed GDK .
- If it's CE with new code or EE, the pipeline creation should be blocked by
The number of jobs has exceeded the limit of 2.
Related to #287669