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

improve caching in CI #128

Merged
merged 1 commit into from
Jan 18, 2024
Merged

improve caching in CI #128

merged 1 commit into from
Jan 18, 2024

Conversation

garymm
Copy link
Owner

@garymm garymm commented Jan 16, 2024

this save disk space and should help cache hit rates

@garymm garymm requested a review from oliverlee January 16, 2024 04:55
@garymm garymm enabled auto-merge (squash) January 16, 2024 04:55
Copy link

codecov bot commented Jan 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (69f50ff) 82.93% compared to head (6984734) 82.77%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #128      +/-   ##
==========================================
- Coverage   82.93%   82.77%   -0.16%     
==========================================
  Files          16       16              
  Lines         627      627              
  Branches       38       38              
==========================================
- Hits          520      519       -1     
  Misses         92       92              
- Partials       15       16       +1     

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

if: github.ref == 'refs/heads/master'
with:
path: "~/.cache/bazel_disk_cache"
key: bazel-disk-test-${{ matrix.toolchain }}-${{ matrix.feature }}
Copy link
Collaborator

Choose a reason for hiding this comment

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

this will fail to save the cache once it is established

is it work deleting the cache so that it can be updated when commits are merged?

Copy link
Owner Author

Choose a reason for hiding this comment

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

Do you think there's something low effort that I should do instead?
Next step I think would be to set up buildbuddy, but I don't want to spend the time to do that just yet.

Copy link
Collaborator

Choose a reason for hiding this comment

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

setting up buildbuddy was very low effort.

< 15 mins would be my guess

Copy link
Owner Author

Choose a reason for hiding this comment

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

OK, done. That was easier than expected!

@garymm garymm force-pushed the garymm/github-cache branch from 1368d0a to 7c91f21 Compare January 18, 2024 04:54
@garymm garymm changed the title only write to cache from master improve caching in CI Jan 18, 2024
@garymm garymm force-pushed the garymm/github-cache branch from 7c91f21 to 2501c9f Compare January 18, 2024 04:55
use buildbuddy for build cache
only write to non-build caches from master, which should save cache
space and increase hit rates.

Change-Id: I33464f548bd63ae790f328c58be767f48e62568b
@garymm garymm force-pushed the garymm/github-cache branch from 2501c9f to 6984734 Compare January 18, 2024 05:00
@garymm garymm merged commit 51a2ddb into master Jan 18, 2024
14 of 15 checks passed
@garymm garymm deleted the garymm/github-cache branch January 18, 2024 05:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants