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

chore(ci): Improve caching #1446

Merged
merged 1 commit into from
Feb 9, 2023
Merged

chore(ci): Improve caching #1446

merged 1 commit into from
Feb 9, 2023

Conversation

haines
Copy link
Member

@haines haines commented Feb 8, 2023

Since branches don't share caches, except for the default branch, we need to warm the cache on main branch pushes to avoid missing the cache on the first build of every PR.

Our caches are quite large, so to reduce eviction pr-test jobs now use common caches for dependencies and build outputs (generated by make warm-cache). The snapshots job re-uses the dependencies cache, but has a separate build cache which is much larger, thanks to cross-compiling.

@codecov
Copy link

codecov bot commented Feb 8, 2023

Codecov Report

Merging #1446 (8963be2) into main (dfb42e9) will increase coverage by 0.19%.
The diff coverage is n/a.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1446      +/-   ##
==========================================
+ Coverage   54.14%   54.33%   +0.19%     
==========================================
  Files         116      116              
  Lines       13086    13086              
==========================================
+ Hits         7085     7110      +25     
+ Misses       5405     5378      -27     
- Partials      596      598       +2     
Impacted Files Coverage Δ
internal/server/tests.go 96.06% <0.00%> (-0.91%) ⬇️
internal/engine/engine.go 63.21% <0.00%> (+0.68%) ⬆️
internal/storage/index/builder.go 84.46% <0.00%> (+7.28%) ⬆️
internal/compile/errors.go 51.56% <0.00%> (+15.62%) ⬆️

@haines haines force-pushed the warm-cache branch 2 times, most recently from 3f82e80 to 62d84de Compare February 8, 2023 19:09
@haines haines marked this pull request as ready for review February 8, 2023 19:12
@haines haines marked this pull request as draft February 9, 2023 08:15
@haines haines force-pushed the warm-cache branch 6 times, most recently from aa77743 to 0b9924c Compare February 9, 2023 10:33
@haines haines changed the title chore(ci): Warm cache on push to main chore(ci): Improve caching Feb 9, 2023
@haines haines force-pushed the warm-cache branch 2 times, most recently from 9d9f362 to 2847bab Compare February 9, 2023 10:49
Signed-off-by: Andrew Haines <haines@cerbos.dev>
@haines haines marked this pull request as ready for review February 9, 2023 11:07
@haines haines merged commit a7a542c into cerbos:main Feb 9, 2023
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.

2 participants