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
Cache golangci-lint cache and Go build cache between runs on CI. #5160
Conversation
… to follow same convention.
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.
Please see comments.
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.
Please see comments.
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.
Please see comments. I see GitHub still submits double reviews :/
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.
Also wondering if we shouldn't be caching $GOMODCACHE.
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.
Also wondering if we shouldn't be caching $GOMODCACHE. GitHub double review submit 🤦♂️
8c8dd56
to
76db2f6
Compare
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.
LGTM, although I guess we can drop the debugging steps by now? Is the PR otherwise all done, considering it's still a draft?
Yep, I need to drop the debugging steps, fix the double-caching from Once I've made those changes, I'll mark this as ready for review. |
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.
LGTM!
What this PR does
This PR introduces caching for golangci-lint's cache and the Go build cache to the CI build.
This improves the performance of each of the affected jobs if a cache hit occurs:
Overall, this improves CI run time by around 4 minutes, which is roughly 20%. For example, compare this run where no cache hits occur with this run where all caches are hit.
This uses GitHub Actions' built-in caching support, and so has the cross-branch caching protections described here.
Which issue(s) this PR fixes or relates to
Relates to #5159
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]