CLDSRV-955: Parallelize docker builds into a matrix#6228
Conversation
Convert the build job into a matrix that builds the cloudserver, cloudserver-testcoverage, pykmip and ci-mongodb images in parallel instead of sequentially, so downstream test jobs no longer wait on a single serial build. All image tags are preserved exactly. The testcoverage image writes to its own cache scope to avoid racing the production build on the shared scope while still reading it for reuse. Federation and the dashboards push are moved to a separate build-federation job (needs: build): they depend on the pushed production image but are not consumed by any test job, so they now run in parallel with the tests rather than blocking them.
Hello tcarmet,My role is to assist you with the merge of this Available options
Available commands
Status report is not available. |
Incorrect fix versionThe
Considering where you are trying to merge, I ignored possible hotfix versions and I expected to find:
Please check the |
❌ 2 Tests Failed:
View the top 1 failed test(s) by shortest run time
View the full list of 2 ❄️ flaky test(s)
To view more test analytics, go to the Test Analytics Dashboard |
Docker build matrix - CI timing impactMeasured on a warm run of this branch (run Build phase
Matrix entry breakdown (warm):
Honest caveats
Note: the functional suite is independently flaky on the shared MPU abort-race teardown (CLDSRV-938), unrelated to this change; this run needed reruns of a couple of single flaky tests to go green. All build/matrix jobs passed on every attempt. |
The testcoverage image is FROM production, so building it as a separate parallel matrix entry forced it to rebuild the production layers (~460s). Build it right after production in the same entry instead, sharing the cloudserver cache scope: it reuses the freshly built production layers (a few seconds). Sequential within one job, so there is no cache-to race. Drops the matrix wall time from being gated by the ~460s testcoverage rebuild to roughly the ~220s production build.
…trix Replace the single build matrix (which used an awkward optional target2 field to squeeze the testcoverage build into the cloudserver entry) with a dedicated build-cloudserver job that builds production then testcoverage sequentially, plus a clean build-images matrix for the standalone pykmip and ci-mongodb images. Downstream test jobs now depend on both build jobs; build-federation depends on build-cloudserver (the production image).
Docker build - updated timing (warm, after restructure)Structure is now a dedicated
vs Honest findings
Flaky note: the functional suite still trips the known MPU abort-race teardown (CLDSRV-938), unrelated to this change. |
Speeds up CI by building the container images in parallel instead of one after another, so the test jobs that depend on them start sooner. The release-only images that depend on the freshly built server image and are not needed by any test are moved off the critical path to run alongside the tests. Image names and tags are unchanged. This is the second of two changes tracked under CLDSRV-955 to reduce the
testsworkflow wall time; the first caches the installed dependency tree.