Skip to content
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

make warehouse do shallow, single-branch clones #1091

Merged
merged 3 commits into from
Nov 16, 2023

Conversation

krancour
Copy link
Member

Fixes #1090

Copy link

netlify bot commented Nov 11, 2023

Deploy Preview for docs-kargo-akuity-io ready!

Name Link
🔨 Latest commit 3580b61
🔍 Latest deploy log https://app.netlify.com/sites/docs-kargo-akuity-io/deploys/6556373ca54d6d0008de164f
😎 Deploy Preview https://deploy-preview-1091.kargo.akuity.io
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

codecov bot commented Nov 11, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (2195706) 50.32% compared to head (3580b61) 50.32%.

Files Patch % Lines
internal/controller/promotion/git.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1091      +/-   ##
==========================================
- Coverage   50.32%   50.32%   -0.01%     
==========================================
  Files         114      114              
  Lines        8089     8088       -1     
==========================================
- Hits         4071     4070       -1     
  Misses       3871     3871              
  Partials      147      147              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Signed-off-by: Kent <kent.rancourt@gmail.com>
@krancour krancour force-pushed the krancour/faster-warehouses branch from a24b6c0 to 44931af Compare November 14, 2023 18:33
Copy link
Contributor

@rbreeze rbreeze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@jessesuen jessesuen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines +105 to +108
// Shallow indicates whether the clone should be with a depth of 1. This is
// useful for speeding up the cloning process when all we care about is the
// latest commit from a single branch.
Shallow bool
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since I only see CloneOptions used one place, is it true that this PR makes it such that all clones performed by kargo are shallow?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No... only the Warehouse reconciler is exercising these options.

The Promotion reconciler still does a full clone (nil options).

@krancour krancour merged commit 29bff30 into akuity:main Nov 16, 2023
@krancour krancour deleted the krancour/faster-warehouses branch November 16, 2023 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

idea: make warehouse controller faster by doing shallow clone
3 participants