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

fix(CI): Cache compilation results #9328

Open
wants to merge 40 commits into
base: main
Choose a base branch
from
Open

fix(CI): Cache compilation results #9328

wants to merge 40 commits into from

Conversation

upbqdn
Copy link
Member

@upbqdn upbqdn commented Mar 14, 2025

Motivation

Solution

Clean-ups

  • Mount lwd's and Zebra's cached states to implicit locations instead of explicitly specifying the location in each test.

Tests

  • CI is noticeably faster.

PR Checklist

  • The PR name is suitable for the release notes.
  • The solution is tested.
  • The documentation is up to date.
  • The PR has a priority label.
  • If the PR shouldn't be in the release notes, it has the
    C-exclude-from-changelog label.

@upbqdn upbqdn added A-devops Area: Pipelines, CI/CD and Dockerfiles C-cleanup Category: This is a cleanup P-Low ❄️ labels Mar 14, 2025
@upbqdn
Copy link
Member Author

upbqdn commented Mar 15, 2025

This PR seems to make CI noticeably faster.

@upbqdn
Copy link
Member Author

upbqdn commented Mar 15, 2025

We could bring the CI time down to ~25 minutes if we moved these three tests to run only on main:

image

@upbqdn upbqdn changed the title change: Optimize CI fix(CI): Cache compilation Mar 17, 2025
@upbqdn upbqdn added the C-exclude-from-changelog Category: The PR should be excluded from the changelog and release notes label Mar 17, 2025
@upbqdn upbqdn changed the title fix(CI): Cache compilation fix(CI): Cache compilation results Mar 17, 2025
@upbqdn upbqdn marked this pull request as ready for review March 17, 2025 11:44
@upbqdn upbqdn requested a review from a team as a code owner March 17, 2025 11:44
@upbqdn upbqdn requested review from arya2 and gustavovalverde and removed request for a team and arya2 March 17, 2025 11:44
Comment on lines +87 to +92
cp -a ${CARGO_TARGET_DIR} ${HOME}/tmp_target && \
cp -a ${CARGO_HOME} ${HOME}/tmp_cargo_home

RUN rm -rf ${CARGO_TARGET_DIR} && rm -rf ${CARGO_HOME} && \
mv ${HOME}/tmp_target ${CARGO_TARGET_DIR} && \
mv ${HOME}/tmp_cargo_home ${CARGO_HOME}
Copy link
Member Author

Choose a reason for hiding this comment

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

This is a rather awful hack. I think there could a cleaner solution, but I coulnd't come up with anything better.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Why is this needed?

Copy link
Member

Choose a reason for hiding this comment

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

This might be the best context to answer that #6169 (comment)

Base automatically changed from fix-ci to main March 18, 2025 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-devops Area: Pipelines, CI/CD and Dockerfiles C-cleanup Category: This is a cleanup C-exclude-from-changelog Category: The PR should be excluded from the changelog and release notes P-Low ❄️
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants