Relax Testcontainers parallelism limit from 1 to 2#12034
Relax Testcontainers parallelism limit from 1 to 2#12034AlexeyKuznetsov-DD wants to merge 3 commits into
Conversation
bric3
left a comment
There was a problem hiding this comment.
I propose a gradle properties for that, that can be manipulated in CI if needed.
This could a good improvement if / when cointainer based tests are moved to their specific job.
|
|
||
| ext.testcontainersLimit = gradle.sharedServices.registerIfAbsent("testcontainersLimit", TestcontainersLimitService) { | ||
| maxParallelUsages = 1 | ||
| maxParallelUsages = 2 |
There was a problem hiding this comment.
suggestion: I propose to use a gradle properties for that. That way it can be controlled in CI or locally.
There was a problem hiding this comment.
Make sense, I will work in this direction.
There was a problem hiding this comment.
Done in aea624e — maxParallelUsages now reads from the testcontainersMaxParallelUsages Gradle property (default 2), documented in gradle.properties, so it can be overridden in CI or locally with -PtestcontainersMaxParallelUsages=N.
|
🎯 Code Coverage (details) 🔗 Commit SHA: 875b30d | Docs | Datadog PR Page | Give us feedback! |
🟢 Java Benchmark SLOs — All performance SLOs passed
PR vs. master results
Commit: Load and DaCapo benchmarks can be triggered manually in the GitLab pipeline. Results will appear in the Benchmarking Platform UI after completion. |
Read maxParallelUsages from the testcontainersMaxParallelUsages Gradle property (default 2) so it can be tuned in CI or locally without a code change, per review feedback. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
aea624e to
875b30d
Compare
There was a problem hiding this comment.
More details
This PR changes Testcontainers parallelism from a hardcoded limit of 1 to a configurable value with default 2, improving CI throughput by ~15% (55→46 min). The property is properly defaulted in gradle.properties, safely accessed via .toInteger(), and overridable per environment. All 28 affected modules are handled uniformly through the same build service. No behavioral regressions detected.
📊 Validated against 8 scenarios · Open Bits AI session
🤖 Datadog Autotest · Commit 875b30d · What is Autotest? · @DataDog review to ask questions · Any feedback? Reach out in #autotest
|
/merge |
|
View all feedbacks in Devflow UI.
The expected merge time in Use ⏳ Merge Commit: a11e18e |
|
PR Shepherd is now watching this PR: fixing basic CI failures, rebasing when it falls behind, and re-queueing after transient merge-queue failures. To disable it, add the If you have any questions, reach the team in #ai-devx-flow. |
What Does This Do
Raises the shared
testcontainersLimitbuild servicemaxParallelUsagesfrom1to2ingradle/java_no_deps.gradle, allowing up to two Testcontainers-backed test tasks to run concurrently.Motivation
The hard limit of
1serialized every test task that uses Testcontainers, throttling Gradle parallelism on GitLab. Relaxing it to2lets more test work run in parallel and improves CI throughput.Additional Notes
1→2) to gain parallelism while keeping resource pressure (containers, memory, ports) in check.~55 mins->~46mins.