Skip to content

Commit 5d1632a

Browse files
nicohrubeccodex
andauthored
ci: shard Cloudflare integration tests (#24726)
Similar to #24676, split Cloudflare integration tests across two CI jobs. Atm this doesn't get us an overall faster wall time but as we'll soon be running more and more tests on cloudflare this could quickly become a bottleneck, getting ahead of this by doing this simple optimization. We can also always add more shards if it becomes necessary. Both shards passed. Compared with a run off develop today: | Cloudflare | Baseline | Two shards | Faster by | | --- | --- | --- | --- | | Test execution (slowest shard) | 5m56s | 3m15s | 2m41s (45%) | | **All Cloudflare jobs finished, from CI start** | **9m31s** | **6m19s** | **3m12s** | Observed timings from one run each. - Baseline: [CI run](https://github.com/getsentry/sentry-javascript/actions/runs/36110233929) · [Sentry trace](https://sentry.sentry.io/explore/traces/trace/c7cd7471a660956b591fea4f99270e09/?project=5899451) - This PR: [CI run](https://github.com/getsentry/sentry-javascript/actions/runs/36114956684) · [Sentry trace](https://sentry.sentry.io/explore/traces/trace/f2b405b0238b2a25f431bd23da2f130f/?project=5899451) Co-authored-by: GPT-6 <codex@openai.com>
1 parent 0808c61 commit 5d1632a

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

‎.github/workflows/build.yml‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -843,11 +843,15 @@ jobs:
843843
run: yarn test --shard=${{ matrix.shard }}/3
844844

845845
job_cloudflare_integration_tests:
846-
name: Cloudflare Integration Tests
846+
name: Cloudflare Integration Tests (${{ matrix.shard }}/2)
847847
needs: [job_get_metadata, job_build]
848848
if: needs.job_build.outputs.changed_cloudflare_integration == 'true' || github.event_name != 'pull_request'
849849
runs-on: ubuntu-24.04
850850
timeout-minutes: 15
851+
strategy:
852+
fail-fast: false
853+
matrix:
854+
shard: [1, 2]
851855
steps:
852856
- name: Check out current commit (${{ needs.job_get_metadata.outputs.commit_label }})
853857
uses: actions/checkout@v7
@@ -864,7 +868,7 @@ jobs:
864868

865869
- name: Run integration tests
866870
working-directory: dev-packages/cloudflare-integration-tests
867-
run: yarn test
871+
run: yarn test --shard=${{ matrix.shard }}/2
868872

869873
job_bundler_plugin_integration_tests:
870874
name: Bundler Plugin Integration Tests (Node ${{ matrix.node }})

0 commit comments

Comments
 (0)