Commit d46862fa authored by Kamil Trzciński's avatar Kamil Trzciński

Merge branch 'leipert-increase-dag-limit' into 'master'

Increase lower DAG `needs` limit from five to ten

See merge request gitlab-org/gitlab!21237
parents dcc29451 4f846b4f
---
title: Increase lower DAG `needs` limit from five to ten
merge_request: 21237
author:
type: changed
...@@ -2256,11 +2256,11 @@ This example creates three paths of execution: ...@@ -2256,11 +2256,11 @@ This example creates three paths of execution:
pipeline will be created with YAML error. pipeline will be created with YAML error.
- We are temporarily limiting the maximum number of jobs that a single job can - We are temporarily limiting the maximum number of jobs that a single job can
need in the `needs:` array: need in the `needs:` array:
- For GitLab.com, the limit is five. For more information, see our - For GitLab.com, the limit is ten. For more information, see our
[infrastructure issue](https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/7541). [infrastructure issue](https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/7541).
- For self-managed instances, the limit is: - For self-managed instances, the limit is:
- Five by default (`ci_dag_limit_needs` feature flag is enabled). - 10, if the `ci_dag_limit_needs` feature flag is enabled (default).
- 50 if the `ci_dag_limit_needs` feature flag is disabled. - 50, if the `ci_dag_limit_needs` feature flag is disabled.
- It is impossible for now to have `needs: []` (empty needs), the job always needs to - It is impossible for now to have `needs: []` (empty needs), the job always needs to
depend on something, unless this is the job in the first stage. However, support for depend on something, unless this is the job in the first stage. However, support for
an empty needs array [is planned](https://gitlab.com/gitlab-org/gitlab/issues/30631). an empty needs array [is planned](https://gitlab.com/gitlab-org/gitlab/issues/30631).
......
...@@ -10,7 +10,7 @@ module Gitlab ...@@ -10,7 +10,7 @@ module Gitlab
delegate :dig, to: :@seed_attributes delegate :dig, to: :@seed_attributes
# When the `ci_dag_limit_needs` is enabled it uses the lower limit # When the `ci_dag_limit_needs` is enabled it uses the lower limit
LOW_NEEDS_LIMIT = 5 LOW_NEEDS_LIMIT = 10
HARD_NEEDS_LIMIT = 50 HARD_NEEDS_LIMIT = 50
def initialize(pipeline, attributes, previous_stages) def initialize(pipeline, attributes, previous_stages)
......
...@@ -852,7 +852,7 @@ describe Gitlab::Ci::Pipeline::Seed::Build do ...@@ -852,7 +852,7 @@ describe Gitlab::Ci::Pipeline::Seed::Build do
it "returns an error" do it "returns an error" do
expect(subject.errors).to contain_exactly( expect(subject.errors).to contain_exactly(
"rspec: one job can only need 5 others, but you have listed 6. See needs keyword documentation for more details") "rspec: one job can only need 10 others, but you have listed 11. See needs keyword documentation for more details")
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment