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

ci: Use rust-cache in policy test workflow #12297

Merged
merged 2 commits into from
Mar 21, 2024
Merged

ci: Use rust-cache in policy test workflow #12297

merged 2 commits into from
Mar 21, 2024

Conversation

olix0r
Copy link
Member

@olix0r olix0r commented Mar 19, 2024

The Swatinem/rust-cache action attempts to cache dependencies for Rust builds.

This change adds this action the policy integration tests to improve test build times.

The Swatinem/rust-cache action attempts to cache dependencies for Rust
builds.

This change adds this action the policy integration tests to improve
test build times.
@olix0r olix0r requested a review from a team as a code owner March 19, 2024 16:47
@olix0r
Copy link
Member Author

olix0r commented Mar 19, 2024

This cuts policy-test-build in half when the cache is warm (i.e. especially important when rerunning).

@olix0r olix0r enabled auto-merge (squash) March 19, 2024 17:10
Copy link
Member

@alpeb alpeb left a comment

Choose a reason for hiding this comment

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

Sweet! 🌮
It appears though this action should be inserted after the rustup calls so the cache is refreshed whenever the rust version changes:

selecting a toolchain either by action or manual rustup calls should happen
before the plugin, as the cache uses the current rustc version as its cache key

https://github.com/Swatinem/rust-cache?tab=readme-ov-file#example-usage

@olix0r olix0r merged commit 5eb6f71 into main Mar 21, 2024
37 checks passed
@olix0r olix0r deleted the ver/rust-cache branch March 21, 2024 18:30
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