Skip to content

ci: DH-20051: shard e2e tests and merge shard reports#1361

Open
SimonVutov wants to merge 7 commits into
deephaven:mainfrom
SimonVutov:DH-20051-Split-up-deephaven-plugins-e2e-tests
Open

ci: DH-20051: shard e2e tests and merge shard reports#1361
SimonVutov wants to merge 7 commits into
deephaven:mainfrom
SimonVutov:DH-20051-Split-up-deephaven-plugins-e2e-tests

Conversation

@SimonVutov

@SimonVutov SimonVutov commented Jun 11, 2026

Copy link
Copy Markdown

This PR shards the end-to-end workflow to reduce overall time and keep full test coverage.
Before: 51-53 mins
After: 22 mins

Changes:

  • Workflow fan-out: e2e.yml now runs a matrix of browser/shard configs: chromium 1/2, chromium 2/2, firefox 1/2, firefox 2/2, webkit 1/2, webkit 2/2.
  • Shard execution: Each matrix job parses its browser and shard index and runs Playwright with project plus shard arguments.
  • Report fan-in: Each shard uploads a blob artifact. A merge-reports job downloads shard blobs and merges them into one final HTML report artifact.
  • Container output persistence: docker-compose.yml mounts blob-report so shard blob outputs are available to artifact upload.

CI reliability fixes:

  • playwright-docker.config.ts no longer overrides reporter in CI, allowing workflow-level blob reporter selection.
  • Dockerfile removes large build-essential install and keeps minimal font install to avoid no-space-left failures on runners.
  • docker-compose.yml removes obsolete compose version field warning.

Current e2e tests:
Screenshot 2026-06-11 at 3 10 59 PM

e2e tests with sharding:
Screenshot 2026-06-11 at 3 11 55 PM

More details, showing how long each separate shard takes:
Screenshot 2026-06-12 at 11 33 15 AM

@SimonVutov SimonVutov requested a review from mofojed June 11, 2026 19:19
@SimonVutov SimonVutov self-assigned this Jun 11, 2026

@mofojed mofojed left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Have you tried this with a failed run to ensure the failure is reported correctly and you can download the report/watch the video?
Local e2e tests still work correctly?

Looking good so far

Comment thread .github/workflows/e2e.yml Outdated
with:
name: playwright-report
path: playwright-report/
retention-days: 90

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We don't need to retain for 90 days, 30 days is fine.

Comment thread .github/workflows/e2e.yml
exit 1
fi

npx -y playwright@1.44.1 merge-reports --reporter html,github ./all-blob-reports

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should probably update playwright as well. v1.44.1 is pretty old. That could be a separate PR though.

Comment thread .github/workflows/e2e.yml

jobs:
e2e-test:
e2e-tests:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

While we should rename this step, we still should have an e2e-test step at the end that passes/fails based on the results. Reason being the branch protection requires an e2e-test step to pass before you can merge a PR:
Image

In web-client-ui we consolidate the result into e2e-results, but I think we should just name it e2e-test here so that it matches the existing branch protection rules... otherwise I need to change those rules as well, and change it for the release branches... easier to just keep the same name.
https://github.com/deephaven/web-client-ui/blob/caeabb02f0abc824a07c505d0a7ca8693dd63cbb/.github/workflows/e2e.yml#L125

Comment thread .github/workflows/e2e.yml Outdated
needs: [e2e-tests]
steps:
- name: Checkout
uses: actions/checkout@v4

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We should use newer versions of these actions, these are old and deprecated

Comment thread .github/workflows/e2e.yml
strategy:
fail-fast: false
matrix:
config: [chromium-1-2, chromium-2-2, firefox-1-2, firefox-2-2, webkit-1-2, webkit-2-2]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

How did you decide on this sharding? Did you take a look at how long each shard takes individually? I seem to recall webkit taking longer which is why we split up webkit on web-client-ui but not chromium/firefox.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Each shard is currently taking about 15 to 22 minutes to complete. I added a screenshot of the shard timings to the PR description for reference. We could split WebKit into 3 shards instead of 2, which might save another couple of minutes, but I think the current setup is reasonably well balanced for now.

Comment thread .github/workflows/e2e.yml Outdated
config: [chromium-1-2, chromium-2-2, firefox-1-2, firefox-2-2, webkit-1-2, webkit-2-2]
steps:
- name: Checkout
uses: actions/checkout@v4

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Update this action

Comment thread tests/Dockerfile Outdated
apt-get update; \
apt-get install build-essential --yes; \
apt-get install fonts-dejavu-core --yes;
apt-get install --no-install-recommends -y fonts-dejavu-core; \

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Always prefer the long form of flags in scripts - it makes it clearer to the casual reader.

Suggested change
apt-get install --no-install-recommends -y fonts-dejavu-core; \
apt-get install --no-install-recommends --yes fonts-dejavu-core; \

Comment thread .github/workflows/e2e.yml Outdated
branches:
- main
- 'release/**'
workflow_dispatch:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I guess there's no reason to remove this. Just probably isn't useful unless for testing.

Comment thread .github/workflows/e2e.yml
- name: Run tests
run: './tools/run_docker.sh ./tests/docker-compose.yml e2e-tests'
run: |
./tools/run_docker.sh ./tests/docker-compose.yml e2e-tests \

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Does each shard need to rebuild the docker image separately? Or do they share the same build image so they don't need to each re-build it?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Yes, each shard currently rebuilds the Docker image separately. We could change this to build once in a dedicated job and reuse that image across the shard jobs, which would save resources. Let me know if you want me to make that change.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'd like to do that if possible

@SimonVutov SimonVutov requested a review from mofojed June 12, 2026 17:44
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.

2 participants