Skip to content

Blazor Server app in .NET 10 fails to reconnect after server restart, unlike .NET 9 #64228

@tossnet

Description

@tossnet

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

When testing Blazor Server apps created from the default Microsoft templates, I noticed a difference in reconnection behavior between .NET 9 and .NET 10 (RC2).

In .NET 9, when the server is stopped and restarted, the client shows the reconnection panel and successfully reconnects after the server restarts.

In .NET 10, the client also shows the reconnection panel but never reconnects, and eventually displays the message:

"Failed to resume the session. Please reload the page."

This seems like a regression because both templates use the same default setup, and the expected behavior should be identical between .NET 9 and .NET 10.

Expected Behavior

After restarting the Blazor Server app, the client should automatically reconnect once the server becomes available again — just like it does in .NET 9.

Steps To Reproduce

You can reproduce this issue using the default Blazor Server + Aspire templates:

  1. Create two new Aspire projects using the default Microsoft templates:
bash
   dotnet new aspire-blazorserver -f net9.0
   dotnet new aspire-blazorserver -f net10.0
  1. Run each solution using the AppHost project:
  2. Open the Blazor Server frontend in a browser.
  3. Stop the 2 projets and restart them.
  4. Observe the reconnection behavior in the browser:
peek_10.mp4

Exceptions (if any)

Template: Blazor Server (Aspire)
OS: Windows 11
Browsers tested: Chrome

.NET Version

10.0.100-rc.2.25502.107

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions