Skip to content

Migrate Performance Metrics to Buildkite pipeline#2310

Merged
wojtekn merged 11 commits intotrunkfrom
add/metrics-comparison-to-buildkite
Dec 30, 2025
Merged

Migrate Performance Metrics to Buildkite pipeline#2310
wojtekn merged 11 commits intotrunkfrom
add/metrics-comparison-to-buildkite

Conversation

@wojtekn
Copy link
Copy Markdown
Contributor

@wojtekn wojtekn commented Dec 23, 2025

Related issues

Proposed Changes

  • I propose migrating Performance Metrics tests from GitHub action to Buildkite.

Testing Instructions

  • Confirm that the build goes through
  • Confirm there is a performance metrics comment under the PR

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

@wojtekn wojtekn self-assigned this Dec 23, 2025
@wojtekn wojtekn marked this pull request as ready for review December 23, 2025 14:15
@wpmobilebot
Copy link
Copy Markdown
Collaborator

wpmobilebot commented Dec 24, 2025

📊 Performance Test Results

Comparing 716b93a vs trunk

site-editor

Metric trunk 716b93a Diff Change
load 7235.00 ms 5502.00 ms -1733.00 ms 🟢 -24.0%

site-startup

Metric trunk 716b93a Diff Change
siteCreation 9101.00 ms 9105.00 ms +4.00 ms 🔴 0.0%
siteStartup 3949.00 ms 3956.00 ms +7.00 ms 🔴 0.2%

Results are median values from multiple test runs.

Legend: 🟢 Improvement (faster) | 🔴 Regression (slower) | ⚪ No change

@wojtekn wojtekn changed the title Add placeholder Performance Metrics step to Buildkite pipeline Migrate Performance Metrics to Buildkite pipeline Dec 24, 2025
@wojtekn wojtekn requested review from a team and mokagio December 24, 2025 15:56
@mokagio mokagio mentioned this pull request Dec 29, 2025
1 task
Comment on lines +42 to +44
echo "--- :information_source: Skipping metrics for non-trunk branch"
exit 0
fi
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Have you considered running this check at the start of the script? This way, if the "skip" branch of the conditional should run, we can avoid installing dependencies and the rest of the setup and save some time.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Took a stab in #2327

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Would it make sense to run this condition as part of pipeline logic, as we do in other steps? For example:

if: build.branch == 'trunk' || build.pull_request.base_branch == 'trunk'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Sounds good @wojtekn .

I see 716b93a implements this and also adds the additional condition of the PR having to be ready for review. Neat.

Ship it!

Comment thread .buildkite/pipeline.yml
key: metrics
agents:
queue: mac
command: bash .buildkite/commands/run-metrics-tests.sh
Copy link
Copy Markdown
Contributor

@mokagio mokagio Dec 29, 2025

Choose a reason for hiding this comment

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

Nitpick: I think calling bash is redundant here because the script already has !#/usr/bin/env bash. Most of the .sh scripts we use as the command steps in other projects are invoked that way.

Suggested change
command: bash .buildkite/commands/run-metrics-tests.sh
command: .buildkite/commands/run-metrics-tests.sh

Update: After looking at the pipeline while working on #2327, I noticed that calling the script via bash is the standard in the pipeline, so it'd be out of place to change it in this PR.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks for confirming that.

@wojtekn wojtekn merged commit 33072e4 into trunk Dec 30, 2025
10 checks passed
@wojtekn wojtekn deleted the add/metrics-comparison-to-buildkite branch December 30, 2025 08:25
@wojtekn wojtekn mentioned this pull request Dec 30, 2025
1 task
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