k8s.io icon indicating copy to clipboard operation
k8s.io copied to clipboard

Speed up image promotion process

Open sbueringer opened this issue 3 years ago • 5 comments

First of all, thank you very much for all the work on the registry and the image promotion process!!

If I understood it correctly, recently the image promotion jobs were changed to sync to additional registries. This slowed down the pull-k8sio-cip and the post-k8sio-image-promo and both now take roughly an hour.

Unfortunately, this has the side effect that the release process in projects like Cluster API now takes > 2 hours, while previously it took 10-15 minutes.

I don't really know much about the jobs, but it looks to me like both jobs are scanning the entire registry / all images in the repo which is the reason why it takes over an hour.

Would it be possible to adapt the jobs to only sync the images that were promoted in the current PR / commit?

If necessary, we could still do a periodic full sync with a periodic job.

sbueringer avatar Oct 18 '22 11:10 sbueringer

More details are available at https://github.com/kubernetes-sigs/promo-tools/issues/637

upodroid avatar Oct 26 '22 17:10 upodroid

Yes, this should be solved via https://github.com/kubernetes-sigs/promo-tools/pull/657

saschagrunert avatar Oct 27 '22 19:10 saschagrunert

We still have to cut a new promo tools release and get the new flag being used.

saschagrunert avatar Oct 28 '22 14:10 saschagrunert

/reopen Let's leave this open until we've confirmed the speed up in prod

spiffxp avatar Oct 29 '22 00:10 spiffxp

@spiffxp: Reopened this issue.

In response to this:

/reopen Let's leave this open until we've confirmed the speed up in prod

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.

k8s-ci-robot avatar Oct 29 '22 00:10 k8s-ci-robot

https://github.com/kubernetes-sigs/promo-tools/pull/657 + https://github.com/kubernetes/test-infra/pull/27855 has had lovely results, thank you!

BenTheElder avatar Nov 02 '22 05:11 BenTheElder

I have one more optimization in my mind which I will try out today. Let's leave this issue open until then.

saschagrunert avatar Nov 02 '22 08:11 saschagrunert

Thank you very much, this really helps a lot!

Just for my understanding. Did I see correctly that the presubmit job is now very quick but the postsubmit takes ~ the same time?

sbueringer avatar Nov 02 '22 08:11 sbueringer

The postsubmit is expeted to take a bit longer, yes. But I think we can still improve both sides by diffing more focused on what needs to be pushed/signed.

saschagrunert avatar Nov 02 '22 08:11 saschagrunert

Just took another look. There was one run with 5m and the others >1h. This probably depends on which images are promoted? (https://prow.k8s.io/job-history/gs/kubernetes-jenkins/logs/post-k8sio-image-promo)

sbueringer avatar Nov 02 '22 08:11 sbueringer

This probably depends on which images are promoted?

Exactly. The official Kubernetes manifest is already huge, so filtering based on the file is not enough. With https://github.com/kubernetes-sigs/promo-tools/pull/661 we now additionally filter based on the digests which should be a significant performance improvement.

saschagrunert avatar Nov 02 '22 09:11 saschagrunert

With https://github.com/kubernetes-sigs/promo-tools/issues/662 we can now close this.

saschagrunert avatar Nov 02 '22 11:11 saschagrunert

/close

saschagrunert avatar Nov 02 '22 11:11 saschagrunert

@saschagrunert: Closing this issue.

In response to this:

/close

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.

k8s-ci-robot avatar Nov 02 '22 11:11 k8s-ci-robot

Thank you!! ❤️ 🎉 👏

CecileRobertMichon avatar Nov 02 '22 18:11 CecileRobertMichon

/reopen ref: https://github.com/kubernetes/k8s.io/pull/4441#issuecomment-1309107480

spiffxp avatar Nov 09 '22 18:11 spiffxp

@spiffxp: Reopened this issue.

In response to this:

/reopen ref: https://github.com/kubernetes/k8s.io/pull/4441#issuecomment-1309107480

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.

k8s-ci-robot avatar Nov 09 '22 18:11 k8s-ci-robot

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot avatar Feb 07 '23 18:02 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle rotten
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot avatar Mar 09 '23 18:03 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

k8s-triage-robot avatar Apr 08 '23 19:04 k8s-triage-robot

@k8s-triage-robot: Closing this issue, marking it as "Not Planned".

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Reopen this issue with /reopen
  • Mark this issue as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close not-planned

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.

k8s-ci-robot avatar Apr 08 '23 19:04 k8s-ci-robot