Fix trace detail span pane on navigation and improve stress/playground apps#18146
Conversation
… links - Close span detail pane when navigating between traces via browser back/forward in the dashboard (fixes #10162) - Enable RabbitMQ auto-activation in TestShop BasketService to avoid timeout on first checkout - Add real cross-trace span links in stress app TraceCreator (50% of cross-trace links now create a navigable trace+span)
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 18146Or
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 18146" |
|
PR testing? Screenshots? Draft? |
There was a problem hiding this comment.
Pull request overview
This PR fixes issue #10162 where navigating back between traces in the dashboard left a stale span detail pane open showing a span from the previous trace. The fix is minimal: clear SelectedData when the trace changes in OnParametersSetAsync, allowing the existing SpanId query parameter logic to re-open the correct span if needed. Additionally, two playground app improvements are included: fixing a checkout timeout in TestShop by eagerly activating the RabbitMQ connection, and making the stress app's cross-trace span links navigable by creating real trace/span records.
Changes:
- Clear
SelectedDatainTraceDetail.razor.cswhen navigating between traces so stale span detail panes are closed - Fix TestShop BasketService checkout timeout by enabling auto-activation and using constructor injection for
IConnection - Enhance the stress app's
TraceCreatorto create real recorded spans for 50% of cross-trace links, making them navigable in the dashboard
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/Aspire.Dashboard/Components/Pages/TraceDetail.razor.cs |
Clear SelectedData when TraceId changes to close stale span detail pane |
playground/TestShop/BasketService/Program.cs |
Set DisableAutoActivation = false to eagerly resolve IConnection at startup |
playground/TestShop/BasketService/BasketService.cs |
Replace lazy IServiceProvider resolution with direct IConnection? constructor injection |
playground/Stress/Stress.ApiService/TraceCreator.cs |
Add CreateLinkedTrace to create real navigable spans for cross-trace links; enrich span names with link metadata |
PR Testing ReportPR: #18146 Artifact Version Verification
Changes Analyzed
Test Scenarios ExecutedScenario 1: Dashboard Component Tests (includes TraceDetailsTests)Status: ✅ Passed Scenario 2: Full Dashboard Unit TestsStatus: ✅ Passed Scenario 3: Live Stress AppHost (manual)Status: Summary
Overall Result✅ Dashboard changes verified — The fix ( |
|
❓ CLI E2E Tests unknown — 115 passed, 0 failed, 2 unknown (commit View all recordings
📹 Recordings uploaded automatically from CI run #27399827982 |
Documents the fix for the span detail pane persisting across trace navigation in the dashboard (microsoft/aspire#18146). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Pull request created: #1250
|
Description
Fixes #10162
Three related improvements to dashboard trace navigation and playground apps:
Dashboard: Close span detail pane on trace navigation — When navigating between traces (e.g., clicking a span link to another trace, then pressing browser Back), the span detail pane from the previous trace was left open showing a span that doesn't belong to the current trace. Now
SelectedDatais cleared whenever the trace changes, and if the new URL includes a?spanId=parameter the correct span is re-opened.TestShop: Fix checkout timeout — The BasketService resolved
IConnectionlazily on first checkout, hitting RabbitMQ connection retries (21s) that triggered the frontend's 10-second resilience timeout. Fixed by enabling auto-activation and using constructor injection.Stress app: Create real cross-trace span links — When the stress app creates span links to other traces, 50% now create an actual recorded trace+span so the link is navigable in the dashboard. The span name also includes link metadata (count, same-trace, cross-trace).
Checklist