Skip to content

[release/11.0-preview4] Implement Circuit.RequestCircuitPauseAsync#66455

Merged
wtgodbe merged 13 commits intorelease/11.0-preview4from
backport/pr-66265-to-release/11.0-preview4
Apr 24, 2026
Merged

[release/11.0-preview4] Implement Circuit.RequestCircuitPauseAsync#66455
wtgodbe merged 13 commits intorelease/11.0-preview4from
backport/pr-66265-to-release/11.0-preview4

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot commented Apr 24, 2026

Backport of #66265 to release/11.0-preview4

/cc @ilonatommy

Implement Circuit.RequestCircuitPauseAsync

It didn't make it to p4 on time.

Description

Adds a new public API Circuit.RequestCircuitPauseAsync that lets server-side code request the connected Blazor client to begin the graceful circuit-pause flow. The method dispatches a JS.RequestPause message onto the circuit's dispatcher (serialized with
renders/event handlers) and returns true if the client was successfully asked to begin pausing.

The client can defer the pause via an optional onPauseRequested callback in CircuitStartOptions.

Design doc: #66244
Fixes #62327

Customer Impact

Enables developers to programmatically trigger circuit pause from server-side code (e.g., during deployments or load balancing), which was previously only possible through client-initiated navigation. Without this, there is no server-side API to gracefully pause a Blazor Server circuit.

Regression?

  • Yes
  • No

Risk

  • High
  • Medium
  • Low

The change is additive - a new public method on Circuit with no modifications to existing behavior. Guarded by state checks (disposed, initialized, connected) and fully idempotent.

Verification

  • Manual (required)
  • Automated

Packaging changes reviewed?

  • Yes
  • No
  • N/A

@github-actions github-actions Bot requested a review from a team as a code owner April 24, 2026 08:36
@ilonatommy ilonatommy self-assigned this Apr 24, 2026
@ilonatommy ilonatommy added area-blazor Includes: Blazor, Razor Components feature-circuit-lifecycle Issues to do with blazor server lifecycle events labels Apr 24, 2026
@ilonatommy ilonatommy added this to the 11.0-preview4 milestone Apr 24, 2026
@wtgodbe wtgodbe merged commit 2698e38 into release/11.0-preview4 Apr 24, 2026
36 checks passed
@wtgodbe wtgodbe deleted the backport/pr-66265-to-release/11.0-preview4 branch April 24, 2026 17:34
@dotnet-policy-service dotnet-policy-service Bot modified the milestone: 11.0-preview4 Apr 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-blazor Includes: Blazor, Razor Components feature-circuit-lifecycle Issues to do with blazor server lifecycle events

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants