Skip to content

Add activities to Blazor Server for distributed tracing #29846

Closed
@rynowak

Description

@rynowak

Describe the bug

The long-lived circuits of Blazor server make distributed tracing not work as expected.

Since each circuit is effectively a long-lived request ... a lot of activity (pun intended) ends up getting traced under the same activity. Basically all outgoing requests/traces from inside of a Blazor server circuit (browser tab) will have the same parent span, which causes them to all get grouped together as a single "root cause" in tracing UIs.

To Reproduce

Create a Blazor server application. Use a button to fire off HTTP requests to another ASP.NET Core endpoint. Hook all of this up to your favorite distributed tracing system and enjoy.

All of the operations you start from a Blazor circuit will end inside the same single logical operation from a tracing POV.

image

Metadata

Metadata

Assignees

Labels

Pillar: Dev ExperiencePriority:1Work that is critical for the release, but we could probably ship withoutaffected-fewThis issue impacts only small number of customersarea-blazorIncludes: Blazor, Razor ComponentsenhancementThis issue represents an ask for new feature or an enhancement to an existing onefeature-blazor-serverfeature-observabilityseverity-majorThis label is used by an internal tooltriaged

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions