You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Address deferred review feedback for the modern dashboard - #21766
Addresses the review feedback from #21412 (Modernize the dashboard experience) that was deferred to the tracking issue #21421. Each item was checked against the current code first. Item 17 was already fixed, and every other item is addressed here. The design questions are answered in a comment below.
Replaces WithDashboardPosition with WithDisplayOrder, backed by its own DisplayOrderAnnotation and transported as resource.displayOrder. Like ResourceUrlAnnotation.DisplayOrder, it's a relative sort key: higher values appear first and resources without one count as 0. The API isn't in a release yet. Polyglot snapshots and AppHosts are updated.
2
Keeps traits as resource properties, as decided in the review, and corrects the comment that described them.
4
Moves tag validation out of the TraitAnnotation constructor into WithTrait, which WithTags goes through. An int parameter covers display order validation.
5
Replaces unresolved_parameter_names with a generic related_resource_names on the notification message, keeping field number 5. The dashboard offers to show the related resources in place of the primary button, and the parameter form still accepts the notification.
7
Restores the CircularBuffer removal checks under #if DEBUG, for buffers up to 1,024 items, so large console log buffers don't bring back the CPU cost.
8, 20
Recordings don't mount a live terminal. The missing-parameters form is read-only for recordings and doesn't accept the live AppHost's prompt.
9
ParameterOverview and MissingParametersPanel edit their own copy of the shared command inputs.
10
Keeps generated input names when a prompt has a dynamically loaded input, because callbacks can read AllInputs regardless of DependsOnInputs. Names that aren't unique are still renamed, because the prompt can't be shown otherwise, and every other input keeps its name. Each prompt input also carries the parameter it is for (InteractionInput.related_resource_name), and the parameter form matches inputs by that field rather than by name. A generated name can then match another, already resolved parameter without the form editing the wrong input.
11, 19
The inline form forwards UpdateStateOnChange. Without an active interaction, its file button runs the set-parameter command.
12
Sums delta counter observations per bucket. Repeated delta numbers are no longer merged at ingestion, because that lost their times, and the SQLite rollup now sums them by observation time instead of keeping the largest, without overflowing. Delta numbers are selected by their end, so one that arrives out of order isn't lost. Rollups and chart totals stay finite without depending on the order of the values, so a sum too large for a double no longer stops the chart from rendering, and chart intervals compare times in nanoseconds like the rollup query. Cloning metric values keeps their count, and delta counter cards show the latest change.
13
Preserves negative levels. The main metrics chart shares this calculation, so it's corrected too.
14, 15
A recording's activity window ends at its last request, or its last error log if it has no requests, and has its own labels. In the summary layout, the live window now refreshes every 30 seconds.
16
Scopes the overview's pending refresh flag to the selection, and queues a refresh after console filter changes cancel one. Adds an internal TelemetryRefreshDelayAsync seam so a test can hold a refresh open.
18
Ctrl-click after "select all" no longer adds a resource kind that's switched off.
21, 22
Display orders come from the requesting run rather than the store, and moves use the displayed tie-break.
23
Localizes the trace back button. main has since localized the activity and insights strings, so this PR only adds the recording-specific ones.
Validation
Aspire.Dashboard.Tests: 2,655 passed
Aspire.Dashboard.Components.Tests: 1,384 passed, after merging main
Aspire.Hosting.Tests, limited to the trait, parameter processor, dashboard service and interaction service test classes: 257 passed
Code generation tests for TypeScript, Python, Go, Java and Rust: 412 passed, before the last review fixes, which didn't change exported API
TestShop.AppHost builds
The regression tests for items 14, 15 and 16 were checked by temporarily undoing each fix and confirming they failed.
Not covered: the polyglot AppHosts were renamed but not run, and nothing was checked in a browser.
Checklist
Is this feature complete?
Yes. Ready to ship.
No. Follow-up changes expected.
Are you including unit tests for the changes and scenario tests if relevant?
Yes
No
Did you add public API?
Yes
If yes, did you have an API Review for it?
Yes
No. Not needed for WithDisplayOrder and DisplayOrderAnnotation, as decided in the review.
Did you add <remarks /> and <code /> elements on your triple slash comments?
Yes
No
No
Does the change make any security assumptions or guarantees?
Yes
If yes, have you done a threat model and had a security review?
Fixes the review feedback on the modern dashboard experience that was
deferred to the tracking issue.
Recordings: don't mount a live terminal, keep the missing-parameters form
read-only and away from the live AppHost's prompt, and end the activity
window at the recording's last request.
Parameters: give each editor its own copy of the shared command inputs,
forward UpdateStateOnChange from the inline form, set files through the
set-parameter command when there's no interaction, and keep generated input
names when a prompt has a dynamically loaded input.
Metrics: sum delta counter observations per bucket, retain them through the
SQLite rollup, and preserve negative levels.
Dashboard: scope default positions to the requesting run, use the displayed
tie-break when moving resources, respect enabled resource kinds when
toggling from "select all", refresh the moving activity window, scope the
overview's pending refresh to the selection, and localize hardcoded strings.
Hosting: replace WithDashboardPosition with WithDisplayPosition and its own
annotation, and move tag validation to WithTags.
Also restores the CircularBuffer removal checks in Debug for small buffers.
All questions are answered, so nothing on this PR is waiting for a decision.
1. Should traits keep using resource properties? (item 2)
Yes. Traits stay as resource.trait.<name> properties. The inaccurate backwards-compatibility comment is corrected.
2. What should replace unresolved_parameter_names? (item 5)
A generic related_resource_names field, in 7642d1f. It names the resources the notification is about and keeps field number 5, and the field hadn't shipped in a release. The dashboard offers to show the related resources in place of the primary button, and showing them doesn't answer the notification. The parameter form still accepts it once it shows every parameter (proto).
3. Is keeping generated names acceptable for item 10?
Yes. Generated names are kept when a prompt has a dynamically loaded input, and only names that aren't unique are renamed.
4. Is a capacity limit the right compromise for CircularBuffer? (item 7)
Yes. The removal checks run in Debug for buffers up to 1,024 items.
5. Is it fine for the display position to be hidden by default? (item 6)
Yes. It appears under "show all" in resource details.
6. Does WithDisplayPosition need an API review?
No.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
Chart calculations undercount recent activity when start timestamps are omitted and produce artificial bucket dips and spikes from floating-point rounding, with targeted regression coverage still missing.
Addresses deferred feedback from #21412, improving correctness and isolation in the modern dashboard while leaving the two design questions in #21421 open.
Changes:
Replaces dashboard-specific positioning with WithDisplayPosition and run-scoped defaults.
Metrics: keep Count when cloning metric values so repeated delta exports
survive chart refreshes, sum delta numbers within a rollup rather than
retaining every row so long windows stay bounded, and show a delta counter
card's latest change rather than its largest export.
Parameters: rename generated input names that aren't unique even when the
prompt has a dynamically loaded input, because the prompt can't be shown
otherwise. Don't let a failed in-progress update take down the circuit.
Validate reserved dashboard tags in WithTrait as well as WithTags.
Activity: anchor a recording without requests on its last error log, exclude
error logs after the window, hide the axis when a recording has no requests,
and only refresh the moving window in the layout that shows it.
The added activity tests only cover recordings; neither exercises this live periodic refresh. Please add a component regression test that stops telemetry, advances a controllable TimeProvider beyond the activity window, and verifies that the request count, error rate and latency expire without another telemetry event. Also verify that disposing the component stops refreshes. Otherwise the stale “last 15 min” behavior can return while all the new tests still pass.
Stop merging repeated delta numbers at ingestion. Each one is a separate
change at its own time, and a merged value only kept the last time, so
exports without a start time were placed in the distant past and bucket
interpolation could round into artificial dips and spikes. Chart intervals
now attribute each export to the time it was observed, and a rollup always
sums its delta numbers.
Add regression tests for the activity window aging out, skipping periodic
refreshes in other layouts and after disposal, a quiet replacement resource
loading while the previous refresh is held, and console filter changes.
When a prompt with a dynamically loaded input has duplicate generated names,
rename only those inputs and give them a free name if their parameter's name
is taken, so load callbacks can still read every other input.
Filter the activity window's error logs by time in the query, before the
limit, so errors after a recording's last request can't use up the limit and
hide the ones in the window.
The query selects the latest 500 error logs from the entire recording before applying the activity window. If 500 errors occur after the window ending near the last request, they are all discarded here and earlier in-window errors never reach Error hotspots. Apply timestamp filters before paging, and select the latest matching logs within that window.
Delta rollups misattribute observations across chart bucket boundaries
Numeric delta rollups combine observations by interval start, then TryCalculateDeltaPoint assigns their entire sum to the latest end time. For example, exports of 4 over (9.5s, 9.9s] and 6 over (9.9s, 10.1s] share a 1-second rollup, so adjacent 10-second chart buckets show null and 10 instead of 4 and 6. Preserve individual observation times or aggregate against the actual chart boundaries, and add a repository-to-calculator regression spanning a boundary.
The collision fallback renames unrelated unique inputs, so dynamic callbacks can still lose their lookup keys. With parameter/input pairs regionParam/Region, Zone/Value, otherParam/Value, and zoneParam/Zone, resolving the duplicate Value names triggers this fallback and renames Region, breaking a callback reading AllInputs["Region"]. Assign collision-free names only to conflicting inputs while preserving unique callback-visible names, and add a regression that executes the callback.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The integer SUM can overflow on valid metric observations, causing GetInstrumentAsync to fail instead of returning chart data even when the total is representable as a finite double.
SQLite's integer SUM throws when integers overflow, which stopped an
instrument's charts and cards loading if the delta values in one rollup were
large enough. Only run it when the magnitudes can't reach the integer range,
and return a larger sum as a double point. Sums in range stay exact.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
The reported checks did not exercise recording read-only terminal/parameter behavior or inline file/dynamic-input workflows in a browser, leaving those paths unverified.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
A component regression test is still needed to verify that a read-only panel neither accepts a pending notification nor claims its inputs interaction, since the existing disabled-controls test does not cover that guard.
Sébastien Ros (@sebastienros) backporting to release/17.0 failed, the patch most likely resulted in conflicts. Please backport manually!
git am output
$ git am --3way --empty=keep --ignore-whitespace --keep-non-patch changes.patchApplying: Address deferred review feedback for the modern dashboardUsing index info to reconstruct a base tree...M src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razorM src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razor.csM src/Aspire.Dashboard/Components/Layout/ResourcesLayout.razor.csM src/Aspire.Dashboard/Components/Pages/ResourceOverview.razorM src/Aspire.Dashboard/Model/ResourceViewModel.csM src/Aspire.Dashboard/Resources/Resources.Designer.csM src/Aspire.Dashboard/Resources/Resources.resxM src/Aspire.Dashboard/Resources/xlf/Resources.cs.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.de.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.es.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.fr.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.it.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.ja.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.ko.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.pl.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.pt-BR.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.ru.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.tr.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hans.xlfM src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hant.xlfM src/Shared/Model/KnownProperties.csM tests/Aspire.Dashboard.Components.Tests/Layout/ResourcesLayoutTests.csM tests/Aspire.Hosting.CodeGeneration.Go.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.goM tests/Aspire.Hosting.CodeGeneration.Java.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.javaM tests/Aspire.Hosting.CodeGeneration.Python.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.pyM tests/Aspire.Hosting.CodeGeneration.Rust.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.rsM tests/Aspire.Hosting.CodeGeneration.TypeScript.Tests/Snapshots/HostingContainerResourceCapabilities.verified.txtM tests/Aspire.Hosting.CodeGeneration.TypeScript.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.tsM tests/PolyglotAppHosts/Aspire.Hosting/Go/apphost.goM tests/PolyglotAppHosts/Aspire.Hosting/Java/AppHost.javaM tests/PolyglotAppHosts/Aspire.Hosting/Python/apphost.pyM tests/PolyglotAppHosts/Aspire.Hosting/TypeScript/apphost.mtsFalling back to patching base and 3-way merge...Auto-merging src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razorCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razorAuto-merging src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razor.csCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Components/Controls/ApplicationSummary.razor.csAuto-merging src/Aspire.Dashboard/Components/Layout/ResourcesLayout.razor.csAuto-merging src/Aspire.Dashboard/Components/Pages/ResourceOverview.razorAuto-merging src/Aspire.Dashboard/Model/ResourceViewModel.csAuto-merging src/Aspire.Dashboard/Resources/Resources.Designer.csAuto-merging src/Aspire.Dashboard/Resources/Resources.resxAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.cs.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.cs.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.de.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.de.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.es.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.es.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.fr.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.fr.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.it.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.it.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.ja.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.ja.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.ko.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.ko.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.pl.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.pl.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.pt-BR.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.pt-BR.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.ru.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.ru.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.tr.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.tr.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hans.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hans.xlfAuto-merging src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hant.xlfCONFLICT (content): Merge conflict in src/Aspire.Dashboard/Resources/xlf/Resources.zh-Hant.xlfAuto-merging src/Shared/Model/KnownProperties.csAuto-merging tests/Aspire.Dashboard.Components.Tests/Layout/ResourcesLayoutTests.csAuto-merging tests/Aspire.Hosting.CodeGeneration.Go.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.goAuto-merging tests/Aspire.Hosting.CodeGeneration.Java.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.javaAuto-merging tests/Aspire.Hosting.CodeGeneration.Python.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.pyAuto-merging tests/Aspire.Hosting.CodeGeneration.Rust.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.rsAuto-merging tests/Aspire.Hosting.CodeGeneration.TypeScript.Tests/Snapshots/HostingContainerResourceCapabilities.verified.txtAuto-merging tests/Aspire.Hosting.CodeGeneration.TypeScript.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.tsAuto-merging tests/PolyglotAppHosts/Aspire.Hosting/Go/apphost.goAuto-merging tests/PolyglotAppHosts/Aspire.Hosting/Java/AppHost.javaAuto-merging tests/PolyglotAppHosts/Aspire.Hosting/Python/apphost.pyAuto-merging tests/PolyglotAppHosts/Aspire.Hosting/TypeScript/apphost.mtserror: Failed to merge in the changes.hint: Use 'git am --show-current-patch=diff' to see the failed patchhint: When you have resolved this problem, run "git am --continue".hint: If you prefer to skip this patch, run "git am --skip" instead.hint: To restore the original branch and stop patching, run "git am --abort".hint: Disable this message with "git config set advice.mergeConflict false"Patch failed at 0001 Address deferred review feedback for the modern dashboardError: The process '/usr/bin/git' failed with exit code 128
Documented new WithDisplayOrder API in dashboard/explore.mdx. Signals: new_public_type (DisplayOrderAnnotation.cs), dashboard_user_facing_page_changed (ResourceOverview.razor, TraceDetail.razor).
Addresses the review feedback from #21412 (Modernize the dashboard
experience) that was deferred to the tracking issue #21421. Each item
was checked against the current code first. Item 17 was already fixed,
and every other item is addressed here. The design questions are
answered in a comment below.
Fixes#21421
| Items | Change |
|---|---|
| 1, 3, 6 | Replaces `WithDashboardPosition` with `WithDisplayOrder`,
backed by its own `DisplayOrderAnnotation` and transported as
`resource.displayOrder`. Like `ResourceUrlAnnotation.DisplayOrder`, it's
a relative sort key: higher values appear first and resources without
one count as 0. The API isn't in a release yet. Polyglot snapshots and
AppHosts are updated. |
| 2 | Keeps traits as resource properties, as decided in the review, and
corrects the comment that described them. |
| 4 | Moves tag validation out of the `TraitAnnotation` constructor into
`WithTrait`, which `WithTags` goes through. An `int` parameter covers
display order validation. |
| 5 | Replaces `unresolved_parameter_names` with a generic
`related_resource_names` on the notification message, keeping field
number 5. The dashboard offers to show the related resources in place of
the primary button, and the parameter form still accepts the
notification. |
| 7 | Restores the `CircularBuffer` removal checks under `#if DEBUG`,
for buffers up to 1,024 items, so large console log buffers don't bring
back the CPU cost. |
| 8, 20 | Recordings don't mount a live terminal. The missing-parameters
form is read-only for recordings and doesn't accept the live AppHost's
prompt. |
| 9 | `ParameterOverview` and `MissingParametersPanel` edit their own
copy of the shared command inputs. |
| 10 | Keeps generated input names when a prompt has a dynamically
loaded input, because callbacks can read `AllInputs` regardless of
`DependsOnInputs`. Names that aren't unique are still renamed, because
the prompt can't be shown otherwise, and every other input keeps its
name. Each prompt input also carries the parameter it is for
(`InteractionInput.related_resource_name`), and the parameter form
matches inputs by that field rather than by name. A generated name can
then match another, already resolved parameter without the form editing
the wrong input. |
| 11, 19 | The inline form forwards `UpdateStateOnChange`. Without an
active interaction, its file button runs the set-parameter command. |
| 12 | Sums delta counter observations per bucket. Repeated delta
numbers are no longer merged at ingestion, because that lost their
times, and the SQLite rollup now sums them by observation time instead
of keeping the largest, without overflowing. Delta numbers are selected
by their end, so one that arrives out of order isn't lost. Rollups and
chart totals stay finite without depending on the order of the values,
so a sum too large for a double no longer stops the chart from
rendering, and chart intervals compare times in nanoseconds like the
rollup query. Cloning metric values keeps their count, and delta counter
cards show the latest change. |
| 13 | Preserves negative levels. The main metrics chart shares this
calculation, so it's corrected too. |
| 14, 15 | A recording's activity window ends at its last request, or
its last error log if it has no requests, and has its own labels. In the
summary layout, the live window now refreshes every 30 seconds. |
| 16 | Scopes the overview's pending refresh flag to the selection, and
queues a refresh after console filter changes cancel one. Adds an
internal `TelemetryRefreshDelayAsync` seam so a test can hold a refresh
open. |
| 18 | Ctrl-click after "select all" no longer adds a resource kind
that's switched off. |
| 21, 22 | Display orders come from the requesting run rather than the
store, and moves use the displayed tie-break. |
| 23 | Localizes the trace back button. `main` has since localized the
activity and insights strings, so this PR only adds the
recording-specific ones. |
- `Aspire.Dashboard.Tests`: 2,655 passed
- `Aspire.Dashboard.Components.Tests`: 1,384 passed, after merging
`main`
- `Aspire.Hosting.Tests`, limited to the trait, parameter processor,
dashboard service and interaction service test classes: 257 passed
- Code generation tests for TypeScript, Python, Go, Java and Rust: 412
passed, before the last review fixes, which didn't change exported API
- `TestShop.AppHost` builds
The regression tests for items 14, 15 and 16 were checked by temporarily
undoing each fix and confirming they failed.
Not covered: the polyglot AppHosts were renamed but not run, and nothing
was checked in a browser.
- Is this feature complete?
- [x] Yes. Ready to ship.
- [ ] No. Follow-up changes expected.
- Are you including unit tests for the changes and scenario tests if
relevant?
- [x] Yes
- [ ] No
- Did you add public API?
- [x] Yes
- If yes, did you have an API Review for it?
- [ ] Yes
- [x] No. Not needed for `WithDisplayOrder` and
`DisplayOrderAnnotation`, as decided in the review.
- Did you add `<remarks />` and `<code />` elements on your triple slash
comments?
- [ ] Yes
- [x] No
- [ ] No
- Does the change make any security assumptions or guarantees?
- [ ] Yes
- If yes, have you done a threat model and had a security review?
- [ ] Yes
- [ ] No
- [x] No
---------
Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com>
(cherry picked from commit 727eaa7)
Conflicts resolved for release/17.0:
- src/Aspire.Dashboard/Resources/Resources.Designer.cs: kept the release
version, added the four new resource properties and removed
ResourceTraitDashboardPosition, matching the merged Resources.resx.
- tests/Aspire.Hosting.CodeGeneration.Go.Tests/Snapshots/TwoPassScanningGeneratedAspire.verified.go:
regenerated with the Go code generation tests on this branch.
Addresses the review feedback from #21412 (Modernize the dashboard
experience) that was deferred to the tracking issue #21421. Each item
was checked against the current code first. Item 17 was already fixed,
and every other item is addressed here. The design questions are
answered in a comment below.
Fixes#21421
| Items | Change |
|---|---|
| 1, 3, 6 | Replaces `WithDashboardPosition` with `WithDisplayOrder`,
backed by its own `DisplayOrderAnnotation` and transported as
`resource.displayOrder`. Like `ResourceUrlAnnotation.DisplayOrder`, it's
a relative sort key: higher values appear first and resources without
one count as 0. The API isn't in a release yet. Polyglot snapshots and
AppHosts are updated. |
| 2 | Keeps traits as resource properties, as decided in the review, and
corrects the comment that described them. |
| 4 | Moves tag validation out of the `TraitAnnotation` constructor into
`WithTrait`, which `WithTags` goes through. An `int` parameter covers
display order validation. |
| 5 | Replaces `unresolved_parameter_names` with a generic
`related_resource_names` on the notification message, keeping field
number 5. The dashboard offers to show the related resources in place of
the primary button, and the parameter form still accepts the
notification. |
| 7 | Restores the `CircularBuffer` removal checks under `#if DEBUG`,
for buffers up to 1,024 items, so large console log buffers don't bring
back the CPU cost. |
| 8, 20 | Recordings don't mount a live terminal. The missing-parameters
form is read-only for recordings and doesn't accept the live AppHost's
prompt. |
| 9 | `ParameterOverview` and `MissingParametersPanel` edit their own
copy of the shared command inputs. |
| 10 | Keeps generated input names when a prompt has a dynamically
loaded input, because callbacks can read `AllInputs` regardless of
`DependsOnInputs`. Names that aren't unique are still renamed, because
the prompt can't be shown otherwise, and every other input keeps its
name. Each prompt input also carries the parameter it is for
(`InteractionInput.related_resource_name`), and the parameter form
matches inputs by that field rather than by name. A generated name can
then match another, already resolved parameter without the form editing
the wrong input. |
| 11, 19 | The inline form forwards `UpdateStateOnChange`. Without an
active interaction, its file button runs the set-parameter command. |
| 12 | Sums delta counter observations per bucket. Repeated delta
numbers are no longer merged at ingestion, because that lost their
times, and the SQLite rollup now sums them by observation time instead
of keeping the largest, without overflowing. Delta numbers are selected
by their end, so one that arrives out of order isn't lost. Rollups and
chart totals stay finite without depending on the order of the values,
so a sum too large for a double no longer stops the chart from
rendering, and chart intervals compare times in nanoseconds like the
rollup query. Cloning metric values keeps their count, and delta counter
cards show the latest change. |
| 13 | Preserves negative levels. The main metrics chart shares this
calculation, so it's corrected too. |
| 14, 15 | A recording's activity window ends at its last request, or
its last error log if it has no requests, and has its own labels. In the
summary layout, the live window now refreshes every 30 seconds. |
| 16 | Scopes the overview's pending refresh flag to the selection, and
queues a refresh after console filter changes cancel one. Adds an
internal `TelemetryRefreshDelayAsync` seam so a test can hold a refresh
open. |
| 18 | Ctrl-click after "select all" no longer adds a resource kind
that's switched off. |
| 21, 22 | Display orders come from the requesting run rather than the
store, and moves use the displayed tie-break. |
| 23 | Localizes the trace back button. `main` has since localized the
activity and insights strings, so this PR only adds the
recording-specific ones. |
- `Aspire.Dashboard.Tests`: 2,655 passed
- `Aspire.Dashboard.Components.Tests`: 1,384 passed, after merging
`main`
- `Aspire.Hosting.Tests`, limited to the trait, parameter processor,
dashboard service and interaction service test classes: 257 passed
- Code generation tests for TypeScript, Python, Go, Java and Rust: 412
passed, before the last review fixes, which didn't change exported API
- `TestShop.AppHost` builds
The regression tests for items 14, 15 and 16 were checked by temporarily
undoing each fix and confirming they failed.
Not covered: the polyglot AppHosts were renamed but not run, and nothing
was checked in a browser.
- Is this feature complete?
- [x] Yes. Ready to ship.
- [ ] No. Follow-up changes expected.
- Are you including unit tests for the changes and scenario tests if
relevant?
- [x] Yes
- [ ] No
- Did you add public API?
- [x] Yes
- If yes, did you have an API Review for it?
- [ ] Yes
- [x] No. Not needed for `WithDisplayOrder` and
`DisplayOrderAnnotation`, as decided in the review.
- Did you add `<remarks />` and `<code />` elements on your triple slash
comments?
- [ ] Yes
- [x] No
- [ ] No
- Does the change make any security assumptions or guarantees?
- [ ] Yes
- If yes, have you done a threat model and had a security review?
- [ ] Yes
- [ ] No
- [x] No
---------
Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com>
(cherry picked from commit 727eaa7)
Adapted for release/17.0, which doesn't have the dashboard changes this
built on in main (#21840, #21861, #21880, #21881, #21943):
- Tags keep release/17.0's Aspire_Dashboard_Tag name
(KnownResourceTraits.DashboardTag); the Aspire_Tag rename is #21881.
- ResourceOrderStore keeps its SQLite storage. The AppHost display order
semantics, GetPositions(resources) and TryMove(..., resources) are ported
onto it, and the store no longer keeps AppHost positions itself.
- ResourceOrderStoreTests: the four new display order tests run against the
SQLite store, with a new store instance standing in for a restart.
- Tests for code that isn't on release/17.0 aren't brought over
(ParameterFormReplacedAndPromptShownAgain, Standalone_RemovedTelemetrySource).
- Resources.Designer.cs and the Go TwoPassScanningGeneratedAspire snapshot
are regenerated against release/17.0.
Combines the stacked dashboard backports into one PR for `release/17.0`.
The commits are cherry-picked in stack order, one per source PR, onto
the current `release/17.0` tip:
1. #22125: Store dashboard tags,
resource order and metric pins in browser local storage (#21840)
2. #22126: Add dashboard
resource-selector dropdown (#21861)
3. #22127: Rename the WithTags
trait from Aspire_Dashboard_Tag to Aspire_Tag (#21881)
4. #22128: Restore single-line
compact rows in the dashboard resource list (#21880)
5. #22129: Allocate the next
dashboard run ID when two dashboards start in the same millisecond
(#21913)
6. #22130: Simplify the
dashboard around its two main jobs (#21943)
7. #22131: Return 400 for OTLP
JSON requests with malformed ids (#21436)
8. #22132: Address deferred
review feedback for the modern dashboard (#21766)
## Conflict resolution
The stack was cut from an older `release/17.0`. Since then, #22123
(Harden Go SDK runtime) landed and regenerated
`TwoPassScanningGeneratedAspire.verified.go`. That conflicted with
#21766, which replaces `WithDashboardPosition` with `WithDisplayOrder`.
The resolution drops `WithDashboardPosition` and regenerates the
snapshot with the current Go generator, so `WithDisplayOrder` now uses
the hardened `s.Err()` pattern. The other seven commits applied cleanly.
## Validation
All `Aspire.Hosting.CodeGeneration.*.Tests` projects pass locally (Go,
Java, Python, Rust, TypeScript).
---------
Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: James Newton-King <james@newtonking.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: David Fowler <davidfowl@gmail.com>
Co-authored-by: davidfowl <95136+davidfowl@users.noreply.github.com>
Co-authored-by: Maddy Montaquila <maddyleger1@gmail.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Maddy Montaquila <maddy@MadBook-Pro-20.local>
Co-authored-by: Taha Koçal <tahakocalgs@gmail.com>
Co-authored-by: Jose Perez Rodriguez <joperezr@microsoft.com>
)
Documents changes from microsoft/aspire#21766
Author: ``@sebastienros``
**Target branch:** Targeting `release/17.0` — the latest release branch
on `microsoft/aspire.dev` — because the source PR has no milestone or
`release/*` base ref to derive a more specific target.
**Why:** The source PR replaces `WithDashboardPosition` with the new
`WithDisplayOrder` API (backed by `DisplayOrderAnnotation`), which
controls resource ordering in the dashboard. Triggered signals:
`new_public_type` (`DisplayOrderAnnotation.cs`) and
`dashboard_user_facing_page_changed` (`ResourceOverview.razor`,
`TraceDetail.razor`).
**Changes:** Updated existing page
`src/frontend/src/content/docs/dashboard/explore.mdx` with a "Resource
display order" section describing `WithDisplayOrder` semantics (higher
values first, unset counts as 0) and an example.
> Generated by [PR Documentation
Check](https://github.com/microsoft/aspire/actions/runs/42886203726) for
#21766 · copilot · auto · 31.5 AIC · ⌖ 1.16 AIC · ⊞ 7.4K ·
[◷](https://github.com/search?q=repo%3Amicrosoft%2Faspire.dev+%22gh-aw-workflow-id%3A+pr-docs-check%22&type=pullrequests)
<!-- gh-aw-agentic-workflow: PR Documentation Check, engine: copilot,
model: auto, id: 42886203726, workflow_id: pr-docs-check, run:
https://github.com/microsoft/aspire/actions/runs/42886203726 -->
<!-- gh-aw-workflow-id: pr-docs-check -->
<!-- gh-aw-workflow-call-id: microsoft/aspire/pr-docs-check -->
---
**Review update:** This PR now also consolidates the still-accurate
parts of #2045 and #2066, which edited the same page:
- Corrected `WithDisplayOrder` semantics. The default order is resource
type then name (`ResourcesLayout.razor.cs`). A saved drag order takes
precedence, and negative values sort after unset resources.
- Added a TypeScript sample (`withDisplayOrder` is `[AspireExport]`) and
noted the `ASPIRERESOURCETRAITS001` experimental diagnostic.
- Contextual resource actions (right-click, Context Menu key, Shift+F10)
from #2045.
- The existing Aspire Outage section's mode is labeled **Hard core**,
not **Hard** (`Resources.resx`), and the section now covers what hard
core mode does and the `O` shortcut (from #2066).
---------
Co-authored-by: aspire-repo-bot[bot] <268009190+aspire-repo-bot[bot]@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Addresses the review feedback from #21412 (Modernize the dashboard experience) that was deferred to the tracking issue #21421. Each item was checked against the current code first. Item 17 was already fixed, and every other item is addressed here. The design questions are answered in a comment below.
Fixes #21421
WithDashboardPositionwithWithDisplayOrder, backed by its ownDisplayOrderAnnotationand transported asresource.displayOrder. LikeResourceUrlAnnotation.DisplayOrder, it's a relative sort key: higher values appear first and resources without one count as 0. The API isn't in a release yet. Polyglot snapshots and AppHosts are updated.TraitAnnotationconstructor intoWithTrait, whichWithTagsgoes through. Anintparameter covers display order validation.unresolved_parameter_nameswith a genericrelated_resource_nameson the notification message, keeping field number 5. The dashboard offers to show the related resources in place of the primary button, and the parameter form still accepts the notification.CircularBufferremoval checks under#if DEBUG, for buffers up to 1,024 items, so large console log buffers don't bring back the CPU cost.ParameterOverviewandMissingParametersPaneledit their own copy of the shared command inputs.AllInputsregardless ofDependsOnInputs. Names that aren't unique are still renamed, because the prompt can't be shown otherwise, and every other input keeps its name. Each prompt input also carries the parameter it is for (InteractionInput.related_resource_name), and the parameter form matches inputs by that field rather than by name. A generated name can then match another, already resolved parameter without the form editing the wrong input.UpdateStateOnChange. Without an active interaction, its file button runs the set-parameter command.TelemetryRefreshDelayAsyncseam so a test can hold a refresh open.mainhas since localized the activity and insights strings, so this PR only adds the recording-specific ones.Validation
Aspire.Dashboard.Tests: 2,655 passedAspire.Dashboard.Components.Tests: 1,384 passed, after mergingmainAspire.Hosting.Tests, limited to the trait, parameter processor, dashboard service and interaction service test classes: 257 passedTestShop.AppHostbuildsThe regression tests for items 14, 15 and 16 were checked by temporarily undoing each fix and confirming they failed.
Not covered: the polyglot AppHosts were renamed but not run, and nothing was checked in a browser.
Checklist
WithDisplayOrderandDisplayOrderAnnotation, as decided in the review.<remarks />and<code />elements on your triple slash comments?