-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Description
Is there an existing issue for this?
- I have searched the existing issues
Describe the bug
Running the Wasm.Performance benchmarks via Docker using main seems to be hitting a 404 error which causes the benchmark driver to time out after 3 minutes. The benchmark never appears to start. This is keeping the Blazor Wasm crank runs from getting results.
The test app itself seems to start and serve the main page, but as soon as the benchmark is started, the app tries to load blazor-frame.html, which returns 404 even though the file is present in /wwwroot/blazor-frame.html inside the container. Because of this, the benchmark harness never posts results back to the driver, which then times out.
Relevant files:
- Benchmark driver: src/Components/benchmarkapps/Wasm.Performance/Driver/Program.cs
- Exec script: src/Components/benchmarkapps/Wasm.Performance/exec.sh
Notes:
- StressRunDuration is not set (non‑stress run).
- The main page and referenced JS/CSS all load (HTTP 200) in web browser.
- Only when the benchmark is actually started via the button do we see the 404 for blazor-frame.html, and the driver never receives any benchmark results.
- It is not 100% clear that this web browser local testing error is the same the dockerfile hits by default but it seems likely.
Expected Behavior
Starting the Wasm.Performance benchmark (via Playwright or manually) should:
- Successfully load whatever frame or host page is required (currently blazor-frame.html).
- Initialize the Blazor WASM benchmark app.
- Post results back to the driver so it can complete without timing out.
There should not be a 3‑minute timeout in a clean run using the repo’s Dockerfile.
Steps To Reproduce
- git clone http://github.com/dotnet/aspnetcore
- cd aspnetcore
- sudo docker build --build-arg gitBranch=main -t benchmarks_dockerfile -f src/Components/benchmarkapps/Wasm.Performance/dockerfile /home/pbibus/AspNetCore/src/Components/benchmarkapps/Wasm.Performance/
- sudo docker create --label benchmarks --name benchmarks_dockerfile-test --privileged --network host benchmarks_dockerfile
- Get the container id from previous command and sub for <container_id>
- sudo docker start benchmarks_dockerfile-393 && sudo docker logs <container_id> -f
The 404 error should show up pretty quick as the docker entrypoint executes with the 3 minute timeout coming after 3 minutes.
Further testing:
If the docker networking is setup properly, you should also be able to open the url output in the docker log in your local webbrowser of choice. If so, a 404 is achievable (when watching dev-tools console) by opening the link in the webbrowser and clicking the run benchmark button.
Other Notes:
- To inspect the container before the 3 minute timeout sudo docker exec -it <container_id> /bin/bash
- I was unable to properly build the project and what not locally/not through docker, so updated src/Components/benchmarkapps/Wasm.Performance/dockerfile as necessary to test different versions of the repo.
Exceptions (if any)
Docker console logs:
Application started.
warn: Microsoft.AspNetCore.Hosting.Diagnostics[15]
Overriding HTTP_PORTS '8080' and HTTPS_PORTS ''. Binding to values defined by URLS instead 'http://127.0.0.1:0'.
warn: Microsoft.AspNetCore.Hosting.Diagnostics[15]
Overriding HTTP_PORTS '8080' and HTTPS_PORTS ''. Binding to values defined by URLS instead 'http://127.0.0.1:0'.
Test app listening at http://127.0.0.1:42397.
[Browser Log]: Failed to load resource: the server responded with a status of 404 (Not Found)
[STDERR] Unhandled exception. System.TimeoutException: Timed out after 00:03:00.
[STDERR] Browser state:
[STDERR]
[STDERR] at Wasm.Performance.Driver.Program.Main(String[] args) in /src/src/Components/benchmarkapps/Wasm.Performance/Driver/Program.cs:line 105
[STDERR] at Wasm.Performance.Driver.Program.Main(String[] args) in /src/src/Components/benchmarkapps/Wasm.Performance/Driver/Program.cs:line 120
[STDERR] at Wasm.Performance.Driver.Program.<Main>(String[] args)
[STDERR] ./exec.sh: line 3: 7 Aborted (core dumped) ./Wasm.Performance.Driver $StressRunDuration
.NET Version
8.0.415 (in the container)
Anything else?
dotnet --info from inside container:
dotnet --info
.NET SDK:
Version: 8.0.415
Commit: 7bd5a8c970
Workload version: 8.0.400-manifests.c414f008
MSBuild version: 17.11.48+02bf66295
Runtime Environment:
OS Name: ubuntu
OS Version: 22.04
OS Platform: Linux
RID: linux-x64
Base Path: /usr/share/dotnet/sdk/8.0.415/
.NET workloads installed:
Configured to use loose manifests when installing new manifests.
There are no installed workloads to display.
Host:
Version: 8.0.21
Architecture: x64
Commit: 362ab6669d
.NET SDKs installed:
8.0.415 [/usr/share/dotnet/sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 8.0.21 [/usr/share/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 8.0.21 [/usr/share/dotnet/shared/Microsoft.NETCore.App]
Other architectures found:
None
Environment variables:
Not set
global.json file:
Not found
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
Web browser console logs:
favicon.ico:1 Failed to load resource: the server responded with a status of 404 (Not Found)
mmr_main.js:1 PageLogger::scheduleLogFlush - scheduling timer
mmr_main.js:1 MMRWarn: MMR readInjectionParameters: input parameter element missing.
blazor-frame.html:1 Failed to load resource: the server responded with a status of 404 (Not Found)
