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: Trim unnecessary builds #24069

Merged
merged 1 commit into from
Dec 22, 2023
Merged

Conversation

def-
Copy link
Contributor

@def- def- commented Dec 21, 2023

This should be much cheaper than waiting for a builder agent to spin up just to check that all docker images already exist and it has to do nothing

Checklist

  • This PR has adequate test coverage / QA involvement has been duly considered.
  • This PR has an associated up-to-date design doc, is a design doc (template), or is sufficiently small to not require a design.
  • If this PR evolves an existing $T ⇔ Proto$T mapping (possibly in a backwards-incompatible way), then it is tagged with a T-proto label.
  • If this PR will require changes to cloud orchestration or tests, there is a companion cloud PR to account for those changes that is tagged with the release-blocker label (example).
  • This PR includes the following user-facing behavior changes:

@def- def- force-pushed the pr-buildkite-trim-build branch 3 times, most recently from 58e6d28 to 8f0a66b Compare December 21, 2023 12:30
@def- def- marked this pull request as ready for review December 21, 2023 12:35
@def- def- requested a review from a team as a code owner December 21, 2023 12:35
This should be much cheaper than waiting for a builder agent to spin up
just to check that all docker images already exist and it has to do
nothing
@def-
Copy link
Contributor Author

def- commented Dec 21, 2023

Example run for nightly showing that trimming builds works: https://buildkite.com/materialize/nightlies/builds/5687#018c8c66-eee5-40c9-8169-07cdac625baa

step["skip"] = True
if step.get("id") == "build-aarch64":
branch = os.environ["BUILDKITE_BRANCH"]
if (
Copy link
Contributor

Choose a reason for hiding this comment

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

Why are the checks for the two architectures asymmetrical?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We already don't run build-aarch64 for PRs, only on main and v*.* branches.

@def- def- enabled auto-merge December 21, 2023 23:08
@def- def- merged commit 57bf39a into MaterializeInc:main Dec 22, 2023
69 of 71 checks passed
@def- def- deleted the pr-buildkite-trim-build branch December 22, 2023 13:42
if step.get("id") == "build-x86_64":
if builds_published(Arch.X86_64):
step["skip"] = True
if step.get("id") == "build-aarch64":
Copy link
Contributor

Choose a reason for hiding this comment

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

It is not necessary here to include the command as done in other places (ident = step.get("id") or step.get("command"))? If so, when is that necessary? @def-

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because the id is build-* in our actual pipelines, we don't have any commands with that name, the command would be something like bin/ci-builder run stable bin/pyactivate -m ci.test.build

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.

3 participants