-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🌱 Improve release staging build speed #9536
🌱 Improve release staging build speed #9536
Conversation
revert to second variant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm happy to get this merged as an experiment - but as with the previous version we should be ready to roll back quickly if needed.
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: killianmuldoon The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@@ -1058,7 +1058,9 @@ release-binary: $(RELEASE_DIR) | |||
|
|||
.PHONY: release-staging | |||
release-staging: ## Build and push container images to the staging bucket | |||
REGISTRY=$(STAGING_REGISTRY) $(MAKE) docker-build-all docker-push-all release-alias-tag | |||
REGISTRY=$(STAGING_REGISTRY) $(MAKE) docker-build-all | |||
REGISTRY=$(STAGING_REGISTRY) $(MAKE) docker-push-all |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
am I correct to understand that docker-push-all
and docker-build-all
won't and can't run in parallel (because push depends on build)? if so which parts are parallelized by using the -j
option? Is it the docker build commands themselves?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
am I correct to understand that docker-push-all and docker-build-all won't and can't run in parallel (because push depends on build)?
yes that's true. in one iteration of the previous PR i got around this with the suggestion of mdbooth by defining "docker-build-% as a dependency of docker-push-%". but this also introduced some complexity in the push target that we decided was not worth the tradeoff
if so which parts are parallelized by using the -j option? Is it the docker build commands themselves?
yep exactly, the default is to run one job at a time, by passing -j 8
each sub-make (e.g. docker-build-all
, docker-push-all
) make will run 8 jobs in parallel
/lgtm |
LGTM label has been added. Git tree hash: 929d2b0e08e5fb25b720878fe2307ad2ffc12635
|
looks like the first job run with the changes was a success, completed in less time than the average of recent runs but not a huge improvement. there is still the variable queue time within Cloudbuild that i assume is leading to some variation in the build times, will be interesting to see more data in the subsequent jobs |
taking a sample of the last 15 runs (as of right now) since the change, the jobs have been completing in ~21 minutes. Looking at the 25 runs prior to that, the average was ~28 mins. decent improvement IMO, going to cherry-pick to the release branches so we have this for the next cycle /cherry-pick release-1.4 |
@cahillsf: new pull request created: #9554 In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/cherry-pick release-1.5 |
@cahillsf: new pull request created: #9555 In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
What this PR does / why we need it:
Last release cut (slack thread for ref) we were blocked pretty early on in the process waiting for the
post-cluster-api-push-images
job to complete. We cut two patch releases (1.4.6
and1.5.1
) with each taking ~28 minutes to complete.This PR improves the speed of the release process by:
-j 8
to themake
command to parallelize each sub-make and-O
to unify the logging output for each jobThe results of my local testing have been promising, with the most recent job with the current changes completing in under 6 minutes: https://a.cl.ly/5zubWldx
Here is some historical testing data from my sandbox:
-j
option vals and machine sizes: https://a.cl.ly/6quw9NJXchanges based on the conversation and work in this reverted PR: #9392
/area release