Files
orca/.github/workflows/release-javascript-benchmark.yml
T
Neil 9bd6272fdf refactor(tooling): organize build, CI, and test owners (#38130)
* refactor(tooling): organize test runtime and maintenance owners

* test(tooling): preserve relocated runtime fixture dependency edges

* refactor(tooling): preserve xterm routing owner checks

* ci(tooling): include routing owner in sparse checkout

* test(tooling): preserve copied workflow dependency closures

* fix(tooling): normalize hashed JSON assets in release parity

* fix(tooling): distinguish asset aliases from literal references

* fix(tooling): frame normalized asset reference payloads

* fix(tooling): normalize decoded JSON asset references

* refactor(tooling): organize build, CI and release owners

* fix(tooling): align moved generator and workflow path contracts

* fix(tooling): update generated plugin bundle owner banners

* test(tooling): create relocated mobile verifier fixture directories

* test(tooling): copy headless detector dependency closure

* test(tooling): align native batch policy fixtures with owner path

* fix(tooling): link moved reliability command to historical evidence

* fix(tooling): preserve nested sandbox owners and canonical guide source

* fix(tooling): target release version owners in checkout fixture
2026-11-04 21:08:19 -08:00

137 lines
5.0 KiB
YAML

name: Release JavaScript comparison
on:
pull_request:
types: [opened, synchronize, reopened, ready_for_review, converted_to_draft]
paths: ['.github/workflows/release-javascript-benchmark.yml']
workflow_dispatch:
permissions:
contents: read
concurrency:
group: release-javascript-comparison-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
ORCA_BACKGROUND_LAUNCH: '1'
ORCA_DIAGNOSTICS_TOKEN_URL: https://www.onorca.dev/diagnostics/token
ORCA_POSTHOG_WRITE_KEY: ci-build-comparison
NODE_OPTIONS: --max-old-space-size=4096
jobs:
bundle:
if: github.event_name != 'pull_request' || github.event.pull_request.draft != true
uses: ./.github/workflows/release-javascript.yml
with:
ref: ${{ github.sha }}
secrets:
ORCA_POSTHOG_WRITE_KEY: ci-build-comparison
measure:
needs: bundle
name: ${{ matrix.mode }} ${{ matrix.host.platform }} ${{ matrix.host.arch }}
runs-on: ${{ matrix.host.os }}
timeout-minutes: 30
strategy:
fail-fast: false
max-parallel: 8
matrix:
mode: [baseline, shared]
host:
- os: ubuntu-latest
platform: linux
arch: x64
- os: ubuntu-24.04-arm
platform: linux
arch: arm64
- os: windows-2022
platform: win32
arch: x64
- os: macos-15
platform: darwin
arch: arm64
steps:
- uses: actions/checkout@v6
with:
ref: ${{ needs.bundle.outputs.source_sha }}
persist-credentials: false
- uses: ./.github/actions/install-node-dependencies
with:
native-runtime: node
persist-native-cache: 'false'
- uses: ./.github/actions/install-mobile-dependencies
- name: Install Linux provider dependencies
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y python3-gi gir1.2-atspi-2.0 at-spi2-core xclip xdotool
- name: Resolve build identity
shell: bash
run: |
RELEASE_TAG="v$(node -p 'require("./package.json").version')"
export RELEASE_TAG
RELEASE_JAVASCRIPT_ARTIFACT='config/scripts/release/javascript-artifacts/release-javascript-artifact.mjs'
if [ ! -f "$RELEASE_JAVASCRIPT_ARTIFACT" ]; then
RELEASE_JAVASCRIPT_ARTIFACT='config/scripts/release-javascript-artifact.mjs'
fi
echo "ORCA_BUILD_IDENTITY=$(node "$RELEASE_JAVASCRIPT_ARTIFACT" identity)" >> "$GITHUB_ENV"
- name: Download shared JavaScript
if: matrix.mode == 'shared'
uses: actions/download-artifact@v8
with:
name: release-javascript
path: .build/release-javascript
- name: Measure release build
shell: bash
env:
MEASUREMENT_MODE: ${{ matrix.mode }}
ORCA_RELEASE_JAVASCRIPT_SOURCE_SHA: ${{ needs.bundle.outputs.source_sha }}
run: |
RELEASE_JAVASCRIPT_BENCHMARK='config/scripts/release/javascript-artifacts/release-javascript-benchmark.mjs'
if [ ! -f "$RELEASE_JAVASCRIPT_BENCHMARK" ]; then
RELEASE_JAVASCRIPT_BENCHMARK='config/scripts/release-javascript-benchmark.mjs'
fi
node "$RELEASE_JAVASCRIPT_BENCHMARK" "$MEASUREMENT_MODE"
- uses: actions/upload-artifact@v7
with:
name: release-javascript-measurement-${{ matrix.mode }}-${{ matrix.host.platform }}-${{ matrix.host.arch }}
path: .build/release-javascript-measurements/
retention-days: 7
comparison:
needs: [bundle, measure]
runs-on: ubuntu-slim
permissions:
contents: read
actions: read
steps:
- uses: actions/checkout@v6
with:
ref: ${{ needs.bundle.outputs.source_sha }}
persist-credentials: false
- uses: actions/setup-node@v6
with:
node-version-file: package.json
check-latest: true
- uses: ./.github/actions/install-node-dependencies
- uses: actions/download-artifact@v8
with:
pattern: release-javascript-measurement-*
path: .build/release-javascript-measurements
- name: Compare build and transfer timings
env:
GH_TOKEN: ${{ github.token }}
run: |
gh api "repos/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID/jobs?per_page=100" > .build/release-javascript-measurements/jobs.json
RELEASE_JAVASCRIPT_BENCHMARK='config/scripts/release/javascript-artifacts/release-javascript-benchmark.mjs'
if [ ! -f "$RELEASE_JAVASCRIPT_BENCHMARK" ]; then
RELEASE_JAVASCRIPT_BENCHMARK='config/scripts/release-javascript-benchmark.mjs'
fi
node "$RELEASE_JAVASCRIPT_BENCHMARK" summary
cat .build/release-javascript-measurements/comparison.md >> "$GITHUB_STEP_SUMMARY"
- uses: actions/upload-artifact@v7
if: always()
with:
name: release-javascript-comparison
path: .build/release-javascript-measurements/comparison.md
retention-days: 30