microsoft / microsoft/aspire

Cannot select specific resource instance in standalone dashboard

Open
#11,769 1 comment 0 reactions 0 assignees View on GitHub
area-dashboard
Dominant language
C#
Stars
6.3k
Forks
991
Avg merge
2d 15h
Merged PRs (30d)
196

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Describe the bug

If the .NET Aspire standalone dashboard has received telemetry from two resources with the same `service.name` but different `service.instance.id`, its resource selector dropdowns show lists like this:

* (All)
* Demo (application)
* Demo-51390961
* Demo-65269311

However, when I select the "Demo-51390961" resource from the list, this selection only flashes from a brief time and the first item of the list is selected instead: "(All)" on the "Structured logs " and "Traces" pages, and "(None)" on the "Metrics" page.

The "Demo (application)" item on the other hand works OK.

### Expected Behavior

When I select "Demo-51390961" from the resource list, it should remain selected, and the page should then display the telemetry from that resource only.

### Steps To Reproduce

Start the .NET Aspire dashboard standalone.

Export telemetry to the dashboard from a program that generates a random `service.instance.id`.

Run the same program again, so that it generates another `service.instance.id`.

Select the "Metrics" page of the dashboard, and select the "Demo (application)" resource. The dashboard shows the corresponding metrics. OK so far.

Select the "Demo-51390961" resource. "(None)" becomes selected instead, and the dashboard does not show any metrics.

### Exceptions (if any)

None.

### .NET Version info

_No response_

### Anything else?

.NET Aspire 9.5.0 dashboard on .NET 8.0.20. The problem also occurs in 9.4.0 and 9.3.0.

likewise describes the resource selector misbehaving. It was fixed in . The problem there was related to dashes in instance IDs; but in my case, the instance IDs are generated using `Guid.NewGuid().ToString("N", CultureInfo.InvariantCulture)` and thus do not have any dashes in them.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.