aspire — Engineering Performance
14 engineers all time · Jan 2025 – Nov 2026 · built 2026-11-30 · GitHub
Performance snapshot
Today's rolling 90-day reading for aspire, compared with the start of the series. Pick a window to move that comparison point.
Avg. perf / dev / mo
+1099.2%
1.73 → 20.77 ETV
Active engineers
±0%
13.0 → 13.0
Features
−8.8pp
36.4% → 27.6%
vs. Microsoft
1.7x
1.3x → 1.7x · +72% above
aspire vs. Microsoft
Per-engineer ETV for aspire against Microsoft as a whole. Both lines are 90-day rolling averages scaled to a 30-day month, so they share one axis and can be read against each other at any point. Pick a window to zoom the chart to it.
Performance Composition
Each month's output split by type of work: Features (new value), Maintenance (sustaining systems), Tests, Docs, and Fixes (rework). The yellow line is output per engineer, so when it rises each engineer is delivering more, whatever the team size did. Unit: Engineering Throughput Value (ETV).
Engineering capacity
Effective engineers behind aspire, against its pre-AI baseline. Each subject has its own: aspire's is 1.73 ETV / dev / mo, its first reading in Q1 2025. Per-engineer ETV divided by that gives a capacity multiple, and that multiple applied to the engineers active in the trailing 90 days turns it into engineer-equivalents. The line is the real headcount, so the gap between line and area is what the leverage is worth. Because each baseline is its own, every subject opens at 1.0x on its first day: multiples measure improvement and are not comparable between subjects.
Knowledge concentration
How dependent is this repo on a small number of engineers? Higher top-1 share = higher key-person risk.
James Newton-King owns 21.0 % of commits.
Behind the numbers
Written summary of the work completed each month.
No monthly reports available yet.
Top engineers
Most impactful commits
Top 10 by ETV in the all-time window.
- 43.5ETVModernize the dashboard experience (#21412) This PR introduces a redesigned dashboard experience. It's an early experiment: we want to learn what works and what doesn't before going further. Users can switch back to the previous dashboard at any time from **Settings**, and the dashboard asks for feedback along the way. <img width="1600" height="1000" alt="testshop-home" src="https://github.com/user-attachments/assets/8380090e-b335-44a0-bc70-36a3391bda63" /> ## What's new - **Home view**: the run's status, live activity, slowest endpoints, busiest resources and recent errors on one page. - **Resource pane**: every page keeps the resource list on the left, with search, filters, kind toggles, multi-selection and Select all. Logs, traces and metrics follow the selected resources. - **Grouping by tags**: resources and their parameters can be grouped by tags, type or state. Tags can come from the AppHost or be added in the dashboard. - **Resource overview**: choose between a summary, cards, a list or a graph, with quick actions on each resource. - **Parameters**: set or delete a parameter's value directly from its overview. - **Metrics**: instruments are shown as cards with live sparklines. You can pin the ones you care about, filter across meters, and group or sort instruments across resources. - **Recordings**: switch between the live run and recorded runs from the header. ## Try it > **⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.** Install the Aspire CLI built from this PR with: ```bash curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 21412 ``` Or run remotely in PowerShell: ```powershell iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 21412" ``` --------- Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com> Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: IEvangelist <7679720+IEvangelist@users.noreply.github.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> Copilot-Session: 2b0b6dd9-44ee-4ba7-82c5-a5ba3b43c5f8 Copilot-Session: 6cc982e7-b012-4f63-ab6f-51ef1f51d849 Copilot-Session: 21d03854-668d-4570-b7fd-179f09f5587d Copilot-Session: 884dec6b-3cc1-481e-b459-1d471c5b4448 Copilot-Session: 599df549-2f63-4a67-8eea-af6fc6bfba28Sébastien Ros · 63c361dd · 2026-10-30
- 36.9ETVAdd opt-in AppHost Server v2 to the CLI bundle (#20897) ## Description The Aspire CLI is the single entry point: **`aspire run` / `aspire start` / `aspire deploy`**. Each command uses the same application model; what changes is how that model is executed. This PR introduces **AppHost Server v2**, separating application authoring from execution. AppHost code describes the application through generated ATS contracts. A separate, long-lived server owns the graph, pipeline scheduling, and workload lifetimes. ### Architecture  The server's **minimal-dependency kernel** owns declarations, references, revisions, and execution authority. Integration-specific libraries stay outside it: portable modules compose the model in the guest, while integration hosts provide runtime services in separate processes. NativeAOT and build-time ATS generation keep runtime scanning and code generation off the execution path. Authoring and execution have independent lifetimes. A guest can disconnect or submit a new revision without inherently restarting compatible workloads. The server validates and schedules pipeline steps; their integration-specific callbacks execute in the guest. Local execution uses DCP and the existing Dashboard. Deployment integrations, such as Compose, consume the same model without becoming part of the kernel. ### Scope Opt in per project in `aspire.config.json`: ```json { "features": { "appHostServerV2": true } } ``` Existing AppHosts continue using managed Hosting by default, with no change to its behavior. The first CLI slice supports TypeScript/Node.js on Windows and Unix. The PR also includes standalone C# prototypes and side-by-side TypeScript/C# Compose integrations. Compose publishing and deployment are bounded, nonshipping demonstrations, not managed Compose parity. Automatic CLI reload, broader integration support, and formal security review remain follow-up work. Real CLI validation covers `run`, detached `start`, `publish`, and `deploy`, including shutdown and Redis persistence. Linux NativeAOT and Windows named-pipe validation passed. Related to #20873. See the [App Model v2 specification](https://github.com/microsoft/aspire/blob/64e5860ad76ca05c743c9c5f1f3d57e00dd7c99c/docs/specs/appmodelv2.md) for details. This PR remains draft. ## Checklist - Is this feature complete? - [ ] Yes. Ready to ship. - [x] 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? - [ ] Yes - If yes, did you have an API Review for it? - [ ] Yes - [ ] No - Did you add `<remarks />` and `<code />` elements on your triple slash comments? - [ ] Yes - [ ] No - [x] No - Does the change make any security assumptions or guarantees? - [x] Yes - If yes, have you done a threat model and had a security review? - [ ] Yes - [x] No - [ ] No --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 5232bd9d-6550-4411-a521-cd6be239f67e Copilot-Session: 7a6644bf-9352-4988-b790-7b2c407f50c0David Fowler · f4ae2cc4 · 2026-10-21
- 33.2ETVAdd SQLite persistence and run history to the Dashboard (#18924) * Add SQLite persistence and run history to the Dashboard * Fix dashboard build after API updates * Fix CLI build and peer trace clearing * Fix Hosting buildJames Newton-King · fc57afa0 · 2026-08-25
- 26.1ETVAdd experimental native tray companion for macOS and Windows (#20096) ## Description Managing several AppHosts should not require repeatedly running `aspire ps`. This PR adds a native **macOS menu-bar and Windows notification-area companion**, backed by the invoking Aspire CLI rather than a separate/private CLI installation. The companion is C# NativeAOT using AppKit and Win32 directly. There is no Swift build, WebView, macOS .NET workload, Windows Forms, or third-party UI framework. The CLI supplies an opt-in, versioned discovery/health stream and exact-instance stop contract; existing unversioned consumers retain their behavior. Related to #20083. **The scope expanded in `bf72a532d9`: Windows now has a functional frontend and bundled payload, not a read-only scaffold.** This remains experimental, not a stable-release or completed-validation claim. See the outstanding Windows runtime and security validation below. ### User-facing usage After this PR's native archive jobs pass, install its CLI using the [PR dogfooding instructions](https://github.com/microsoft/aspire/blob/main/docs/dogfooding-pull-requests.md) in archive mode. Invoke that installation explicitly, rather than an older CLI on PATH: ```sh aspire tray start aspire tray start aspire tray stop ``` The first start extracts and launches the bundled companion; another start restores the existing icon without another watcher. Stop, or **Quit Aspire**, exits the companion and its discovery child, not the AppHosts. Starting from another CLI installation restores the running companion; stop and start to adopt the new CLI/bundle. Both frontends expose AppHost health, Open Dashboard, exact-instance Stop with a native default-Cancel confirmation, history, pinning, explicit Start for offline projects, folder/editor actions, Documentation, and About. Merely opening a submenu never starts an AppHost. History stores source paths and preferences, not process identities or dashboard login URLs. Missing pins are pruned; clearing recent history requires confirmation and preserves pins. **Upgrading an earlier preview:** quit it using its original CLI's `aspire tray stop` command or **Quit Aspire** before starting this build. The current macOS control socket and instance lock live under `~/.aspire/tray/runtime`; `~/Library/Application Support/Aspire/Tray/` is the legacy state/log location, not the active control endpoint. An older preview may use a different endpoint. Windows state and diagnostics live under `%LocalAppData%\Aspire\Tray`. ### Implementation - Native frontends live in `src/Aspire.Tray/`, with shared tests in `tests/Aspire.Tray.Tests/`. The projects use normal repository build, analyzer, versioning, and test conventions. - macOS payloads include `tray/Aspire Tray.app/Contents/MacOS/aspire-tray`. Windows x64 and ARM64 payloads include `tray/aspire-tray.exe` and the required adjacent `tray/Aspire.ico`. Payload verification runs before embedding. - Startup is acknowledged by the native UI loop. CLI/helper bundle leases cover the handoff until the GUI owns its lease; stop waits for the exact tray process lifetime. - A single CLI discovery process supplies replacement snapshots, resource-health summaries, and heartbeats. Stop revalidates path, PID, and process start time, without force escalation or project-wide fallback. Independent AppHosts can stop concurrently. - The Windows frontend owns native menus/icons, handles Explorer restoration and artwork invalidation, and uses current-user-secured singleton/control primitives. Windows x64 native smoke runs when the runner has an interactive Explorer/input desktop. Hosted Windows ARM64 UI smoke is temporarily excluded by explicit maintainer decision following the investigation below. Both unavailable desktops and the ARM64 exclusion are explicitly reported, not counted as UI coverage. - Official macOS whole-app signing/notarization and Windows executable signing are wired into packaging. Wiring is not evidence that release signing has been validated. ### Validation - **Earlier macOS build:** installed-artifact lifecycle, exact-stop safety, payload verification, and native smoke evidence is recorded in [the testing report](https://github.com/microsoft/aspire/pull/20096#issuecomment-5656474737). That report covers the earlier build, not the later Windows/UX expansion. - **Earlier local follow-up on Apple Silicon:** 189 tray tests passed (four Windows-only tests skipped), 252 tray-packaging/selector tests passed, and 320 targeted CLI tests passed (one case-sensitive-filesystem test skipped). Local Windows builds are not Windows runtime tests. - **Windows ARM64 investigation on `fbedb3e2fb`:** [same-runner ARM64 → x64 → ARM64 SDK controls](https://github.com/microsoft/aspire/actions/runs/35373950404/job/105696457894), with verified PE architectures and standard Windows artwork, all rejected `Shell_NotifyIconW(NIM_ADD)` with and without `NIF_SHOWTIP`, despite a responsive Explorer notification area. The actual Aspire ARM64 native smoke then failed registration too. The root cause remains unresolved; these results do not establish a defect specific to Aspire interop or prove a runner defect. - **Explicit temporary coverage reduction on `c68909d371`:** the maintainer approved excluding only hosted Windows ARM64 native UI smoke. [ARM64 publishing, payload verification, packaging and upload passed](https://github.com/microsoft/aspire/actions/runs/35377958296/job/105708101588), with an explicit warning and job-summary notice that native UI behavior was **not validated**. [Windows x64 native UI smoke and packaging passed](https://github.com/microsoft/aspire/actions/runs/35377958296/job/105708101710). The manual ARM64 smoke remains available; restoring hosted ARM64 UI coverage requires further investigation. The exclusion is not a fix for the registration failure or evidence of release readiness. ### Screenshots / Recordings > **This PR includes UI changes.** Screenshots/recordings of the current macOS and Windows menus, health/pinning/history, default-Cancel confirmations, and icon restoration are still needed. <!-- Add screenshots/recordings here --> ### Remaining validation and limitations - **Before shipping:** passing Windows ARM64 native UI smoke, Windows installed-bundle lifecycle coverage, real monitor/DPI testing, official signing/notarization/Authenticode validation, and formal security/threat-model review remain outstanding. Windows x64 fixture-based native smoke passed, but it does not validate live AppHost connectivity; Windows runtime validation is not complete. - Intel Mac runtime validation, login startup, automatic tray upgrade handoff, and long-running log management remain follow-up work. The CLI backend means one extra long-lived native process. - macOS icon recovery uses an undocumented AppKit saved-position preference and cannot guarantee visibility on crowded/notched menu bars. Very long home-directory paths can exceed the macOS socket-path limit. - Linux is unsupported. This experimental PR must not be read as a stable-release claim. ### Security considerations The same-user IPC endpoints, profile lock/state/log files, native process launching, persisted history, and bundle lifetime/signing paths require formal review. Control IPC uses current-user restrictions and fixed lifecycle messages plus process identity. Subprocesses use absolute executable paths and argument lists, not shell command construction. Dashboard URLs can contain credentials and are not persisted in history or raw discovery logs. Stop revalidates PID and lifetime and never escalates or falls back to every instance of a project. ## Checklist - Is this feature complete? - [ ] Yes. Ready to ship. - [x] 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 - New CLI commands and an opt-in wire contract; no hosting integration or supported .NET library API is added. CLI layout model types are executable implementation details. - If yes, did you have an API Review for it? - [ ] Yes - [x] No - 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? - [x] Yes - If yes, have you done a threat model and had a security review? - [ ] Yes - [x] No --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Sébastien Ros <1165805+sebastienros@users.noreply.github.com> Co-authored-by: Sebastien Ros <sebastienros@gmail.com> Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: Mitch Denny <midenn@microsoft.com> Copilot-Session: c091eda9-8768-406b-bd20-d760fee3a090David Fowler · 8eec461e · 2026-10-01
- 25.3ETVDavidfowl/ts apphost (#13705) * Add support for TypeScript and Python AppHost projects - Introduced AppHostRunner and AppHostRunnerFactory for managing different AppHost types. - Implemented validation and execution logic for TypeScript (apphost.ts) and Python (apphost.py) AppHosts. - Enhanced ProjectLocator to detect and handle TypeScript and Python AppHost files. - Added AppHostType enum to represent different AppHost project types. * Add support for TypeScript and Python AppHost projects with language selection and execution * feat: Implement RemoteAppHost with JSON-RPC communication - Added ProjectModel class to scaffold and manage the GenericAppHost project. - Introduced Instruction models for handling various commands (Create, Run, Pragma, Declare, Invoke). - Developed InstructionProcessor to execute instructions and manage application builders. - Created JsonRpcServer to handle client connections and execute instructions via JSON-RPC. - Implemented OrphanDetector to monitor the host process and exit if it is no longer running. - Added Program class to initialize and start the JsonRpc server with graceful shutdown handling. * feat: Implement RemoteAppHost client and distributed application builder with JSON-RPC support * feat: Implement TypeScript code generation service and models - Added ICodeGenerationService interface for generating TypeScript code from Aspire packages. - Created TypeScriptCodeGenerator class for generating TypeScript SDK from the Aspire application model. - Introduced ApplicationModel, IntegrationModel, ResourceModel, and related classes to represent the application structure. - Developed client and distributed application builder for managing resources and executing instructions in TypeScript. - Added TypeScript project files and dependencies for the new code generation functionality. * feat: Update TypeScript AppHost with launch settings support and environment variable handling * feat: Update Aspire.Hosting version references and improve version handling logic * feat: Add documentation for Polyglot AppHost support in Aspire CLI * feat: Enhance polyglot AppHost support with settings.json integration and Redis SDK generation * Implement AppHost project handling for Python and TypeScript - Added IAppHostProject interface for defining common methods for AppHost projects. - Created AddPackageContext class to encapsulate package addition context. - Implemented PythonAppHostProject class to handle Python AppHost projects, including validation, running, and package management. - Implemented TypeScriptAppHostProject class to handle TypeScript AppHost projects, including validation, running, and package management. - Introduced IAppHostProjectFactory interface for creating AppHost project handlers based on type. - Added methods for managing dependencies and environment setup for both Python and TypeScript projects. * feat: Refactor AddCommand to streamline project handling and remove unused dependencies * feat: Refactor code generation services to use ICodeGenerator interface and implement TypeScriptCodeGenerator * feat: Enhance project model to handle NuGet.config creation and retrieval based on local package source * feat: Implement IAsyncDisposable support for InstructionProcessor and JsonRpcServer for graceful shutdown * feat: Enhance InstructionProcessor and JsonRpcServer for cancellation support and thread safety * feat: Implement bidirectional callback support in TypeScript AppHost and enhance environment variable handling * feat: Introduce extension method provider and enhance code generation for polyglot SDKs * feat: Enhance ProjectModel to support DCP package name generation and improve environment variable handling * Refactor: Remove TypeScript client and distributed application code - Deleted client TypeScript definitions and implementations, including callback registration and remote app host client logic. - Removed distributed application builder and resource builder classes, along with their associated methods and types. - Eliminated launch settings reader and related functions for managing application launch configurations. - Cleaned up index files by removing exports related to the deleted modules. - Removed package.json and package-lock.json files as they are no longer needed. * feat: Implement callback registration and proxy generation for .NET interactions in TypeScript * feat: Enhance TypeScript AppHost with command line argument handling and error propagation; add ListProxy for .NET collections * feat: Add ReferenceExpression support and enhance indexer handling in TypeScript and .NET interactions * feat: Enhance TypeScript AppHost with ReferenceExpression support and proxy handling; update InstructionProcessor for marshalled results * feat: Update TypeScriptCodeGeneratorService to support dev mode regeneration based on ASPIRE_REPO_ROOT configuration * Refactor: Remove Python AppHost support and related files - Removed Python AppHost project handling from AppHostProjectFactory and related classes. - Deleted PythonAppHostProject.cs and its associated logic for validation and execution. - Updated AppHostLanguage and AppHostType enums to exclude Python. - Modified InitCommand and NewCommand to no longer create Python AppHost templates. - Adjusted RunCommand and ProjectLocator to eliminate Python-specific checks. - Cleaned up comments and documentation to reflect the removal of Python support. * Implement Remote Host JSON-RPC Server with Orphan Detection - Added RemoteAppHostService to handle JSON-RPC methods for executing instructions, invoking methods, and managing properties. - Introduced JsonRpcServer to manage client connections over a Unix domain socket, including graceful shutdown and client disconnection handling. - Implemented OrphanDetector as a background service to monitor the parent process and trigger shutdown if it dies. - Integrated orphan detection into the server startup process, allowing for automatic shutdown on parent process termination. - Enhanced error handling and logging throughout the server and service methods. * feat: Implement Remote Host server with JSON-RPC support and enhance instruction processing * feat: Add support for list-like objects in SetProperty method with index validation * Add JSON-RPC callback invoker and object registry for remote hosting - Implement JsonRpcCallbackInvoker to handle callback invocations using JSON-RPC. - Create ObjectRegistry to manage registration and lookup of .NET objects for marshalling to/from TypeScript. - Update RemoteAppHostService to utilize the new JsonRpcCallbackInvoker. - Add unit tests for InstructionProcessor and ObjectRegistry to ensure functionality. - Implement TestCallbackInvoker for testing callback invocations. * feat: Enhance instruction processing with type conversion and callback handling * feat: Implement callback handling improvements to prevent deadlocks and enhance client disconnection logging * feat: Add AppHost project factory and TypeScript code generator to service collection * feat: Add TestLanguageService and update service collection for language handling * feat: Implement service resolution methods in InstructionProcessor and JsonRpcServer * feat: Add publishing functionality to AppHost projects with enhanced error handling and backchannel support * feat: Add Publish Mode support for TypeScript apphosts with detailed architecture and command flow * refactor: Simplify polyglot apphost documentation and enhance clarity on TypeScript support * fix: Improve error handling in PublishAsync to signal backchannel completion on exceptions * refactor: Remove deadlock test for async callbacks in CallbackDeadlockTests * refactor: Remove Python AppHost implementation and add shared CodeGeneratorService for TypeScript projects * feat: Implement TypeScript AppHost project support - Added IAppHostProject interface for handling various AppHost types. - Created TypeScriptAppHostProject class to manage TypeScript AppHost projects, including validation, running, and publishing. - Introduced AddPackageContext and PublishContext for managing package addition and publishing processes. - Implemented IAppHostProjectFactory for creating AppHost project handlers based on type. - Updated service collection in tests to include IGenericAppHostProjectFactory for dependency injection. * feat: Enhance TypeScript AppHost creation with generated SDK integration * refactor: Simplify TypeScript AppHost and NewCommand by removing redundant main function * refactor: Remove unused test-marshalling.ts file to clean up the codebase * feat: Add apphost.run.json generation for dashboard/OTLP configuration and include tsx as a devDependency * refactor: Update application startup logic to use WaitForShutdownAsync for better error handling * Enhance AppHost project handling and instance management - Updated AppHostProjectFactory to map single-file .cs apphosts to project-based handlers. - Refactored DotNetAppHostProject to streamline process management and improve error handling during app host execution. - Added GetProjectFilePath method to GenericAppHostProject for easier access to project file paths. - Extended IAppHostProject interface with CheckAndHandleRunningInstanceAsync method for better instance management. - Implemented CheckAndHandleRunningInstanceAsync in TypeScriptAppHostProject to manage running instances of GenericAppHost. - Improved logging and error handling across various components to enhance debugging and user feedback. * refactor: Enhance build and backchannel completion handling in RunCommand and AppHostProjectContext * refactor: Improve error handling in RunAsync and TypeScript AppHost execution * refactor: Update polyglot apphost documentation for improved clarity and structure * refactor: Implement fluent chaining for Redis container configuration and enhance TypeScript code generation with thenable wrappers * refactor: Enhance TypeScript proxy generation with additional $id property and improve thenable method handling * refactor: Replace GenericAppHost references with AppHostServer in TypeScript project files * refactor: Update log message to reflect AppHost server connection in TypeScript code generator * refactor: Remove ICodeGenerator interface and TypeScriptCodeGeneratorService, streamline TypeScript code generation in TypeScriptAppHostProject * refactor: Remove GenericAppHostProjectFactory and ICodeGenerator, replace with AppHostServerProjectFactory in CliTestHelper * Refactor AppHost Project Handling - Updated the project factory to retrieve AppHost projects based on the app host file instead of the type. - Removed the AppHostType enum and related logic, simplifying the project detection process. - Enhanced the IAppHostProject interface to include language identifiers and detection patterns. - Implemented language-specific project handling for C# and TypeScript, including scaffolding and validation logic. - Modified the LanguageService to work with IAppHostProject instead of AppHostLanguage, allowing for more flexible project management. - Updated tests to reflect changes in project handling and ensure compatibility with the new structure. * refactor: Simplify TypeScript app host project validation by removing aspire.json checks * refactor: Enhance AppHost server project handling by integrating IDotNetCliRunner and ICertificateService * refactor: Implement AppHost server build and TypeScript SDK generation in TypeScriptAppHostProject * refactor: Remove IInteractionService dependency from BuildAsync method and encapsulate AppHost server build logic * refactor: Replace Console output with ILogger for TypeScript AppHost process logging * refactor: Replace Console.WriteLine with ILogger.LogWarning for missing local project notification * refactor: Disable Aspire SDK code generation for AppHost server project metadata * refactor: Simplify BuildAppHostServerAsync and streamline npm install process * refactor: Expand RPC methods documentation for guest-host interactions * refactor: Add environment variable for original apphost project directory in AppHostServerProject and use it in InstructionProcessor * refactor: Enhance TypeScript apphost error handling and output reporting * refactor: Add channel configuration support for non-.NET projects and update project file creation methods * refactor: Update project handling in UpdateCommand and implement package update logic in AppHost projects * Refactor TypeScript Code Generation and Instruction Processing - Updated TypeScriptCodeGenerator to replace CreateBuilderInstruction with InvokeInstruction for invoking methods on distributed applications. - Modified InstructionModels to introduce CreateObjectInstruction and CreateObjectResult for creating instances dynamically. - Enhanced InstructionProcessor to handle CREATE_OBJECT instructions, including argument resolution and instance creation. - Removed service resolution methods from JsonRpcServer as they are no longer needed. - Added comprehensive unit tests for CREATE_OBJECT and INVOKE instructions, ensuring correct behavior for various scenarios including argument handling and error cases. * refactor: Update model class generation to handle enums and remove unnecessary ReferenceClass wrappers * refactor: Implement static property accessors and JSON-RPC methods for TypeScript integration * Add TypeScript code generation tests and related resources - Introduced TypeScript code generation tests for various components. - Added snapshots for generated integration and resource files. - Implemented RemoteAppHostClient and associated proxy classes for .NET object interaction. - Created test types including TestRedisResource and TestDatabaseResource for testing purposes. - Added utility methods for generating and managing resources in tests. - Included package.json and types.ts definitions for TypeScript project setup. * Refactor JSON-RPC server methods and enhance TypeScript client - Removed the `ExecuteInstructionAsync` method from `JsonRpcServer` and added `InvokeStaticMethod` and `CreateObject` methods to handle static method invocation and object creation. - Updated TypeScript client to utilize the new RPC methods for invoking methods and creating objects, replacing the previous instruction-based approach. - Added tests for the new `CreateObject` and `InvokeStaticMethod` functionalities in `InstructionProcessorTests`. - Introduced a new extension method `WithBuilderCallback` for resource builders to support callback configurations. - Enhanced error handling for unknown assemblies, types, and missing required arguments in the new RPC methods. * refactor: Simplify RemoteAppHostClient and remove unused instruction types * Refactor ApplicationModel and introduce DistributedApplicationBuilderModel - Removed MethodMappings from ApplicationModel and replaced it with BuilderModel. - Created DistributedApplicationBuilderModel to encapsulate builder and application types for code generation. - Implemented DistributedApplicationBuilderModelFactory to reflect on IDistributedApplicationBuilder and DistributedApplication types. - Updated IWellKnownTypes to include DistributedApplicationType and DistributedApplicationExecutionContextType. - Removed Mapping class as it is no longer needed. - Enhanced RoType to include Namespace property. - Updated TypeScript code generation to reflect changes in generated proxies and methods. - Added tests to verify expected methods for ConfigurationManager and ServiceProvider. * refactor: Enhance TypeScript code generation with enum definitions and method overload handling * refactor: Remove unused integration and resource generation methods and related tests * feat: Implement code generation visitor pattern for application model - Added `CodeGeneratorVisitor` class to handle code generation for distributed applications. - Introduced `IModelVisitor` interface for traversing the application model. - Implemented methods for visiting application models, builder models, proxy types, integrations, resources, methods, and properties. - Added support for emitting enums and additional classes in the generated output. - Refactored existing code to utilize the new visitor pattern for better organization and maintainability. - Added `TestPersistenceMode` enum to the generated TypeScript output. * refactor: Simplify method overload handling and improve code generation structure * feat: Enhance TypeScript code generation with support for interface resource builders and fluent chaining methods - Introduced new context records for method parameters and proxy methods to streamline code generation. - Refactored the TypeScriptCodeGenerator to buffer methods for thenable class generation. - Removed unused resource builder classes and their corresponding tests. - Updated ApplicationModel to re-aggregate resources after discovering interface types. - Added support for generating fluent chaining methods for resource builders, including IResourceWithConnectionString. - Improved the handling of method overloads and parameter classes in TypeScript generation. * feat: Add support for circular and nested callbacks in resource builders * refactor: Streamline enum handling in TypeScript code generation * feat: Enhance code generation for resource builders and proxies - Introduced a mapping for generated class names to discovered types in CodeGeneratorVisitor. - Updated the discovery process to register types needing generated classes. - Refactored resource type emission to utilize the new mapping. - Added methods for emitting callback proxy types and additional classes. - Improved TypeScript generated proxies to include CancellationToken and Task wrappers. - Updated method signatures in generated proxies to reflect new types and improve type safety. - Enhanced the generated TypeScript classes for better clarity and usability. * Enhance TypeScript code generation for delegate types and async callbacks - Refactor `FormatActionType` to `FormatDelegateType` to handle both Action and Func delegate types. - Implement logic to differentiate between Action and Func delegates, formatting their TypeScript signatures accordingly. - Introduce `FormatJsReturnType` to properly format return types for Func delegates, including handling Task types. - Update `FormatJsType` to recognize delegate types and format them using the new delegate formatting logic. - Add new test cases in `TestExtensions.cs` to validate async delegate callbacks and various parameter types. * feat: Enhance TypeScript code generation with support for additional delegate edge cases and unwrap Task types * feat: Enhance registerCallback to support single and multi-argument callbacks with automatic argument unpacking * feat: Introduce thenable API for fluent async chaining in TypeScript proxies and enhance resource handling * feat: Add Code Generator Architecture section and detail visitor pattern for language support * Refactor Indexer and Method Resolution Tests to use RpcOperations - Updated IndexerOperationsTests to replace InstructionProcessor with RpcOperations. - Modified method calls in tests to reflect the new RpcOperations usage. - Added new RpcOperationsTests to cover various RPC operation scenarios including method invocation, property access, and indexer operations. - Ensured all tests validate expected behavior and error handling for both standard and static methods. * feat: Update TypeScript code generation to use assembly and type names for static method invocations * feat: Refactor CallbackProxyFactory to improve proxy creation and caching mechanism * refactor: Update marshaling logic to enhance JSON-RPC compatibility and simplify type handling * refactor: Remove ResolveValueObject method and update SetIndexerByStringKey to use JsonElement * Refactor tests to use System.Text.Json.Nodes instead of System.Text.Json - Updated all test files to replace JsonDocument with JsonNode for parsing JSON. - Changed the way JSON objects are created and accessed in tests to improve readability and maintainability. - Ensured that all instances where JSON parsing was done now utilize the new JsonNode API. * Enhance JSON-RPC support with JsonNode for argument marshalling and error handling - Updated the JSON-RPC error response format to include detailed error codes. - Refactored argument handling in CallbackProxyFactory to use JsonNode instead of object. - Modified ICallbackInvoker interface to accept JsonNode for callback arguments. - Adjusted JsonRpcCallbackInvoker to handle JsonNode in async invocation methods. - Changed JsonRpcServer methods to return JsonNode for consistency in object representation. - Updated ObjectRegistry to marshal .NET objects to JsonObject for JSON-RPC transport. - Introduced new RpcContracts for handling object references and reference expressions. - Enhanced tests to validate the new JsonNode handling in various scenarios. * feat: Enhance JSON-RPC marshalling to support primitive arrays, lists, and dictionaries * feat: Enhance JSON-RPC support for byte arrays, nullable types, and collections * feat: Add POCO validation for deserialization and enhance interface handling in RPC operations * feat: Add support for CancellationToken management in JSON-RPC, including creation and cancellation methods * Implement RPC authentication and security policy for RemoteAppHost - Added secure random authentication token generation for RPC communication in TypeScriptAppHostProject. - Enhanced RemoteAppHostClient to support authentication with the server using the generated token. - Updated TypeScriptCodeGenerator to retrieve and validate the authentication token from environment variables. - Introduced authentication checks in RemoteAppHostService, requiring clients to authenticate before accessing RPC methods. - Implemented a SecurityPolicy class to manage assembly access permissions, allowing only specified assemblies to be accessed via RPC. - Updated RpcOperations to enforce security policy checks during method invocations and object creations. - Added comprehensive unit tests for authentication and security policy enforcement, ensuring blocked assemblies cannot be accessed. * feat: Implement socket file permissions for enhanced security * fix: Correct formatting in polyglot apphost security section and update RemoteAppHostClient comment * fix: Ensure authToken is non-nullable in authentication method * feat: Add hot reload support using nodemon and enhance RemoteHost server behavior * feat: Enhance JSON configuration to support additional properties and improve nodemon installation check * fix: Update nodemon arguments to include SIGTERM signal for better process management * fix: Optimize shutdown process by using fire-and-forget for StopAsync method * feat: Enhance logging and disposal mechanisms in RemoteHost services * feat: Improve backchannel service by adding socket management and cleanup logic * feat: Add auto-reconnect functionality to AppHostCliBackchannel and update connection methods * fix: Suppress exceptions during enumerator disposal and improve reconnection wait logic * feat: Enhance RPC methods with detailed logging for better traceability * Add ATS intrinsic types and builder exports for distributed applications - Introduced AtsIntrinsics.cs to define intrinsic Aspire types recognized by ATS. - Created BuilderExports.cs to expose properties and lifecycle events of IDistributedApplicationBuilder. - Added CoreExports.cs for core ATS exports supporting polyglot app host capabilities. - Enhanced ContainerResourceBuilderExtensions.cs with new methods for container resource management. - Updated DistributedApplicationExecutionContext.cs to include Aspire context type attribute. - Implemented ExecutableResourceBuilderExtensions.cs for adding executable resources. - Enhanced ParameterResourceBuilderExtensions.cs with methods for parameter and connection string resources. - Updated ProjectResourceBuilderExtensions.cs to support setting replicas for project resources. - Enhanced ResourceBuilderExtensions.cs with various resource management methods. - Added unit tests for AspireExportAnalyzer to validate export method attributes and parameters. * feat: Introduce ATS (Aspire Type System) with capability error handling and marshalled handles - Added CapabilityError class for structured error handling during ATS capability invocations. - Introduced Handle class to represent typed handles for .NET objects in the ATS system. - Updated RemoteAppHostClient to support invoking ATS capabilities and automatically wrap results in Handle objects. - Enhanced wrapIfProxy function to handle marshalled handles alongside legacy proxy objects. - Expanded types.ts with definitions for MarshalledHandle, AtsError, and related types. - Updated CapabilityDispatcher to handle generic method invocations and improved exception handling. - Modified RemoteHostServer to load ATS assemblies from appsettings.json for better configuration management. - Updated README.md to reflect changes in server initialization and configuration. - Added nodemon as a development dependency for improved development workflow. * feat: Enhance Redis integration with new capabilities and management options * feat: Add support for Redis container with password configuration * feat: Update Redis container export methods to include specific port configuration * feat: Introduce ATS capability model and scanner for code generation - Added AtsCapabilityInfo model to represent discovered capabilities for code generation. - Implemented AtsCapabilityScanner to scan assemblies for [AspireExport] attributes and create capability models. - Created AtsParameterInfo model to represent parameters in ATS capabilities. - Enhanced IntegrationModel to include discovered ATS capabilities. - Updated AspireExportAttribute to allow method name specification for generated SDKs. - Added unit tests for ATS TypeScript code generation, ensuring capabilities are correctly discovered and method names are derived as expected. - Generated TypeScript SDK files reflecting new capabilities and methods. * feat: Implement ATS type mapping and export attributes - Added AtsTypeMapping class for mapping CLR types to ATS type IDs based on AspireExportAttribute. - Enhanced RoAssembly to load custom attributes for assembly scanning. - Updated AspireExportAttribute to support type mapping at method, type, and assembly levels. - Introduced AtsTypeMappings.cs for centralizing assembly-level type mappings. - Modified IntegrationModel to utilize the new AtsTypeMapping for capability scanning. - Updated TypeScript code generation tests to reflect changes in ATS type mappings and capabilities. * feat: Enhance polyglot apphost documentation with type system details and integration guidelines * feat: Add support for [AspireContextType] capabilities and enhance context type scanning * feat: Add ATS exports for dictionary, list, logging, notification, and service operations * fix: Correct formatting and clarify ATS-compatible return type in polyglot apphost documentation * refactor: Replace string literals with AtsTypeMapping constants for type IDs across multiple files * Remove obsolete security policy tests and related classes; add new type hierarchy tests for resource type management. * Remove TypeScriptCodeGeneratorTests.cs file and its associated test cases * Add runtime reflection wrappers and enhance resource builder extensions - Introduced RuntimeTypeInfo, RuntimeMethodInfo, RuntimeParameterInfo, RuntimePropertyInfo, RuntimeAttributeInfo, and RuntimeAssemblyInfo to provide reflection capabilities for types, methods, properties, and attributes. - Enhanced ResourceBuilderExtensions to support adding environment variables with reference expression values, enabling dynamic expressions in polyglot hosts. - Updated tests to validate the new runtime reflection functionality and resource builder enhancements. - Added ReferenceExpression and related functionality for creating and serializing reference expressions in TypeScript. - Implemented AtsCapabilityScannerTests to validate type mapping and method name derivation for ATS capabilities. * refactor: Update project references and streamline AtsTypeMapping class for runtime reflection * Refactor ATS Type System: Replace ConstraintTypeId with ExtendsTypeId - Updated AtsCapabilityInfo to remove ConstraintTypeId and replace it with ExtendsTypeId. - Modified AtsTypeScriptCodeGenerator to utilize ExtendsTypeId for method generation and capability handling. - Refactored AtsBuilderModelFactory to categorize capabilities based on ExtendsTypeId instead of ConstraintTypeId. - Removed TypeHierarchy class and its related tests, simplifying capability dispatching logic. - Adjusted CapabilityDispatcher to eliminate AppliesTo validation, relying on CLR type checks for argument validation. - Updated tests to reflect changes in capability registration and invocation logic. * refactor: Simplify resource handling by removing IResourceHandle and consolidating TestContext and TestRedisBuilder classes * Refactor ATS capability scanning and resource model handling - Removed ResourceModel class as it is no longer needed. - Updated CapabilityDispatcher to use a unified capability scanner. - Enhanced AtsCapabilityInfo to include original target type ID and expanded target type IDs. - Improved AtsCapabilityScanner to collect resource types from capability parameters and return types. - Added methods to collect all interfaces implemented by a type, including inherited interfaces. - Updated tests to verify correct capability scanning and resource type handling. - Adjusted TypeScript code generation to reflect changes in capability structure and resource handling. * refactor: Deduplicate capabilities in builder model and enhance DistributedApplicationBuilder with addTestRedis method * refactor: Exclude application builders from resource builder list in SDK generation * Refactor AspireExport attributes to remove versioning and improve consistency - Updated all AspireExport attributes in DictionaryExports, ListExports, LoggingExports, NotificationExports, ServiceExports, and other related files to remove versioning (e.g., "@1") and standardize the format to use only the method name. - Added a Name property to IAtsAssemblyInfo and RuntimeAssemblyInfo to retrieve the simple name of the assembly. - Adjusted tests to reflect changes in capability IDs and ensure they match the new format. - Updated generated TypeScript SDK to align with the new capability ID format. * refactor: Update ATS Type ID format and simplify Capability Scanner reference * refactor: Clarify method overloading uniqueness requirement and enhance diagram representation * Refactor ATS TypeScript Code Generation: Consolidate transport and types into a single transport.ts file - Introduced transport.ts to encapsulate callback functions, error handling, and handle management. - Removed the obsolete types.ts file, merging its contents into transport.ts. - Updated tests to reflect changes in file structure and naming conventions. - Adjusted generated TypeScript files to utilize the new transport layer. - Ensured backward compatibility by maintaining existing interfaces and functionality. * refactor: Update capability ID format in tests for consistency and clarity * refactor: Update README to clarify RemoteHost capabilities and architecture * refactor: Introduce RunningInstanceManager for handling running AppHost instances * refactor: Update code block syntax in polyglot-apphost documentation for clarity * refactor: Enhance ProjectLocator to utilize IAppHostProjectFactory for improved project detection and handling * Refactor project locator tests to remove unused FindExecutableProjectsAsync method - Removed the FindExecutableProjectsAsync method from various project locator implementations and tests. - Updated related tests to eliminate references to the removed method. - Adjusted the TestAppHostProjectFactory to allow custom validation logic for app host projects. - Cleaned up test cases to focus on the primary functionality of locating app host projects without the executable project search. * refactor: Update TypeScript AppHost template for improved clarity and resource handling * refactor: Add method to extract valid TypeScript method names from capability method names * refactor: Remove unused DictionaryExports and ListExports classes * refactor: Remove unused type imports and update invokeCapability type in TestRedisBuilder * refactor: Improve comments and enhance stream handling in JsonRpcServer * refactor: Add TypeScript support feature toggle in Program.cs * refactor: Enable polyglot support by conditionally adding language option in InitCommand and NewCommand * refactor: Clarify socket path comment for cross-platform handling in AspireClient * refactor: Clarify comment regarding CLI and project layering in project files * refactor: Enhance callback handling by adding support for callback parameters and return types * Refactor context type handling and property capabilities - Updated [AspireContextType] attribute to derive type ID as {AssemblyName}/{TypeName}. - Enhanced context property capabilities to include getter and setter distinctions. - Modified code generation for TypeScript to support fluent accessors for context types. - Adjusted tests to validate new context property capabilities and derived type IDs. - Improved handling of context properties in CapabilityDispatcher for getter and setter methods. * Refactor ATS Type Mapping and Exports - Removed explicit AtsTypeId assignments in assembly attributes, allowing automatic derivation from type names. - Updated AtsTypeMapping to derive type IDs from assembly and type names, enhancing consistency. - Introduced ExposeProperties functionality in relevant types, allowing for better context handling. - Modified tests to reflect changes in type ID formats, ensuring alignment with new conventions. - Updated TypeScript code generation to match new ATS type ID structure. - Enhanced clarity in comments and documentation throughout the codebase. * refactor: Update ATS type IDs to use derived assembly and type names for consistency * refactor: Remove AspireCallback attribute requirement for delegate types and enhance callback handling * refactor: Improve type ID derivation and enhance capability scanning consistency * feat: Enhance ATS export capabilities with method exposure and ignore attributes - Added `IsContextMethod` property to `AtsCapabilityInfo` to indicate auto-generated method accessors. - Updated `AtsCapabilityScanner` to support method exposure via `[AspireExport(ExposeMethods = true)]`. - Implemented logic to ignore specific properties and methods using the new `[AspireExportIgnore]` attribute. - Introduced `CollectionExports` for intrinsic collection capabilities, supporting `Dict` and `List` operations. - Created `AspireExportIgnoreAttribute` to exclude members from ATS export. - Added `RoSubstitutedMethod` and `RoSubstitutedParameterInfo` for handling generic methods with substituted parameters. - Enhanced reflection interfaces to retrieve custom attributes for properties and methods. - Updated TypeScript code generation tests to reflect changes in capability naming and structure. * refactor: Update ATS type ID derivation to use full type names and improve consistency across type mappings * refactor: Update context type documentation to reflect changes in class generation and improve clarity * refactor: Introduce AtsConstants for type ID management and update references across the codebase * refactor: Enhance type mapping and handling in ATS code generation and improve TypeScript output consistency * refactor: Introduce AtsCapabilityKind and AtsTypeKind enums for improved capability and type handling in code generation * Refactor ATS Type Handling: Introduce AtsTypeRef for Enhanced Type Metadata - Added AtsTypeRef class to encapsulate type metadata for parameters and return types. - Updated AtsParameterInfo to use AtsTypeRef instead of obsolete properties. - Modified AtsCapabilityInfo to include ReturnType as AtsTypeRef. - Refactored AtsCapabilityScanner to create and utilize AtsTypeRef instances for type resolution. - Enhanced AtsConstants to support new type categories including Array, List, and Dict. - Updated TypeScript code generation to reflect changes in type handling. - Adjusted unit tests to validate new type reference structure and ensure backward compatibility. * refactor: Enhance type handling by introducing AtsTypeRef for improved type metadata and processing * feat: Enhance ATS reflection and capability scanning - Added `GetGenericParameterConstraints` method to `RoReflectionWrappers` and `RuntimeReflectionWrappers` to retrieve generic parameter constraints as `IAtsTypeInfo` objects. - Updated `AtsCapabilityInfo` to replace `ExpandedTargetTypeIds` with `ExpandedTargetTypes`, changing the type from `IReadOnlyList<string>` to `IReadOnlyList<AtsTypeRef>`. - Modified `AtsCapabilityScanner` to handle the new `ExpandedTargetTypes` structure and ensure correct type references are used. - Refactored `AtsTypeInfo` to replace `ImplementedInterfaceTypeIds` with `ImplementedInterfaces`, changing the type to `IReadOnlyList<AtsTypeRef>`. - Updated tests to verify the new structure and ensure correct behavior of capabilities related to container resources and generic constraints. - Added new snapshots for capabilities to reflect changes in the generated TypeScript code. * feat: Enhance TypeScript code generation with additional test cases and context handling - Added support for DTO parameters and mutable collection return types in TypeScript generation. - Implemented handling for ReferenceExpression parameters and callback context wrappers. - Introduced new test types and extended existing functionality for better coverage and validation. - Updated internal type aliases to improve clarity and prevent user exposure. * refactor: Update TypeScript code generation to use property-like object pattern for context properties * feat: Enhance TypeScript code generation with union type support for interface handles and base type hierarchy expansion * feat: Introduce TargetParameterName for improved method signature handling in code generation * feat: Implement 2-pass scanning for capabilities and type info to enhance cross-assembly type expansion * Refactor code structure for improved readability and maintainability * feat: Introduce AspireUnion attribute for union type support in properties and parameters * feat: Enhance TypeScript code generation with async method support for non-builder return types and improve resource handling * feat: Add support for additional environment variable in API container callback * Refactor capability handling to support asynchronous operations - Updated CapabilityHandler delegate to return Task<JsonNode?> instead of JsonNode?. - Modified RegisterContextTypeProperty and RegisterContextTypeMethod to handle async capabilities. - Changed Invoke method to InvokeAsync for better async support. - Updated JsonRpcServer to call InvokeAsync. - Adjusted tests to accommodate async changes and ensure proper functionality. - Enhanced AtsMarshaller to correctly identify and serialize IReadOnlyDictionary types. - Updated type ID derivation logic to use full type names for better uniqueness. - Added tests for property setters and async method invocations. * feat: Enhance capability scanning to handle nested context types and improve error diagnostics * feat: Update callback handling to use positional keys for arguments in TypeScript and C# integration * feat: Enhance capability handling by updating method invocation paths and adding new dictionary and list operations * feat: Enhance AspireDict and AspireList with dynamic handle resolution and passthrough support - Updated AspireDict to resolve handles dynamically using a getter capability if necessary. - Introduced AtsPassthroughAttribute to allow bypassing ATS type validation for collection operations. - Modified transport layer to support handle wrapping with typed wrapper instances. - Enhanced callback registration to handle positional arguments and wrap handles appropriately. - Updated TypeScript generated code to reflect changes in dictionary and list capabilities. - Added serialization for JSON-RPC transport in various context classes. * feat: Add output collector to context for improved error handling and diagnostics across commands * feat: Add output collector to AddPackageContext for improved error handling and diagnostics * feat: Add TypeScript callback handle wrapping and collection wrappers for improved type safety and usability * fix: Update ATS Type IDs in documentation for consistency and clarity * refactor: Simplify UnwrapAttributeValue method for handling ImmutableArray<CustomAttributeTypedArgument<string>> * feat: Enhance ATS type mapping to support 'any' type for object parameters and update related documentation * docs: Update formatting for AspireList and Handle types for improved clarity * refactor: Update handle ID format to use instance numbers and improve documentation clarity. * refactor: Remove obsolete properties from AtsCapabilityInfo and AtsParameterInfo for cleaner code * Refactor handle registration and retrieval to use numeric IDs - Updated tests to reflect changes in handle ID format from "type:instance" to just numeric instance IDs. - Modified assertions in tests to validate the new handle ID structure. - Removed unnecessary parsing tests for handle IDs as the format has changed. - Adjusted related functionality in HandleRegistry to support the new ID format. * Update snapshot files to set ReturnsBuilder to true for optional string, persistence, and Redis capabilities * refactor: Implement VerifyInitializer to ensure single initialization across test assemblies * Refactor code structure for improved readability and maintainability * refactor: Update JSON serialization context and add UserSecretsId to AppHostServerProject * refactor: Simplify process management in TypeScript AppHost by removing redundant cleanup code * refactor: Implement graceful shutdown on server disconnect in TypeScript client connections * refactor: Enhance AspireExportAnalyzer to support additional ATS-compatible types and attributes * Refactor: Remove internal handle type aliases and base classes for DistributedApplication and Builder - Deleted internal type aliases for BuilderHandle and ApplicationHandle. - Removed the DistributedApplicationBase class, which provided the run() method and handle management. - Removed the DistributedApplicationBuilderBase class, which managed handles for builders. - Cleaned up the code by eliminating unnecessary comments and sections related to these classes. * refactor: Add capability kind tests and thenable pattern code generation tests for TypeScript * Refactor promise handling in resource classes to improve readability and consistency - Updated promise resolution in multiple resource promise methods to use 'obj' instead of 'b' for clarity. - Ensured all validator callbacks return the result of the validator function. * refactor: Enhance AppendValueProvider to support IResourceBuilder for value provider handling * refactor: Enhance TypeScript code generation to support DTO types and improve builder options handling * feat: Initialize Vite frontend with React and TypeScript - Added package.json for Vite frontend setup with React and TypeScript. - Created App component to fetch and display API data. - Added index.css for basic styling. - Set up main.tsx for rendering the App component. - Configured TypeScript with tsconfig.json and tsconfig.node.json. - Created vite.config.ts for Vite server configuration with API proxy. - Updated AtsTypeScriptCodeGenerator to filter out property getters/setters. - Enhanced RoReflection wrappers to include IsSpecialName property. - Added AspireExport attributes for JavaScript and PostgreSQL resources. - Improved service discovery and resource builder extensions with descriptive exports. * chore: update dependencies to React 19 and Vite 7 for improved performance and features * Refactor code structure for improved readability and maintainability * feat: Implement core Aspire types and transport layer - Added ReferenceExpression class for creating and serializing reference expressions. - Introduced ResourceBuilderBase, AspireList, and AspireDict classes for resource management. - Developed transport layer with Handle, CapabilityError, and callback registration. - Implemented AspireClient for JSON-RPC connection handling and capability invocation. - Added error handling for ATS capabilities and structured error responses. * feat: Enhance ATS code generation with enum support and context management - Added methods to scan assemblies and return an AtsContext for code generation. - Updated ICodeGenerator interface to generate code from AtsContext instead of separate capabilities and DTO types. - Introduced AtsEnumTypeInfo to represent enum types discovered during scanning. - Enhanced AtsCapabilityScanner to collect and manage enum types during assembly scanning. - Updated AtsMarshaller to handle unmarshalling of enums from string and numeric values. - Added tests for enum handling in marshalling and capability dispatching. - Updated TypeScript code generation to include generated enums and their usage in DTOs and options. * feat: Remove authentication token requirement for RPC connections and update related documentation * feat: Update polyglot apphost documentation with enhanced callback handling and argument serialization details * feat: Add compatibility notes for ATS type system to enhance guest runtime stability and API evolution * feat: Add Docker Compose environment support and enhance RPC call managementDavid Fowler · e94fdf3a · 2026-01-13
- 24.7ETVAdd Aspire editor assistance language model tools (#19414) ## What changed Adds **six new editor-assistance language-model tools** and hardens the existing `aspire_apphost_start` and `aspire_apphost_stop` tools, which already landed in microsoft/aspire#19134. Eight tools are covered here; only six are introduced by this PR. Enable the Aspire tools in Copilot Chat's tool picker in a trusted workspace. Replace `apphost.cs` with an exact discovered AppHost path. Multi-root workspaces require the folder prefix, such as `Lifecycle/apphost.cs`. ## Six new tools | Tool | What it does | Example input | | --- | --- | --- | | `aspire_debug_session_status` | Inspects one AppHost, or an exact resource's runtime state, health, and debug context. | `{"appHostPath":"apphost.cs","resourceName":"api"}` | | `aspire_explain_launch_failure` | Returns the latest retained failure's stage, bounded category, and suggested actions. Does not return raw compiler errors. | `{"appHostPath":"apphost.cs"}` | | `aspire_open_dashboard` | Opens an editor-controlled AppHost's Dashboard using the configured presentation, or an external browser by default. Does not return its URL. | `{"appHostPath":"apphost.cs"}` | | `aspire_open_output` | Opens the Output panel and selects Aspire Extension after confirmation. Does not read or return channel contents. | `{}` | | `aspire_list_debug_sessions` | Lists active AppHosts controlled by this editor, with their state, mode, and controller. Does not enumerate child resources. | `{}` | | `aspire_hot_reload_status` | Reports whether C# Dev Kit Hot Reload is enabled and potentially applicable, with evidence and fallback actions. Never applies or verifies an edit. | `{"appHostPath":"apphost.cs","resourceName":"api"}` | ### Existing lifecycle tools, hardened here | Tool | What it does | Example input | | --- | --- | --- | | `aspire_apphost_start` | Starts through the editor in `run` or `debug` mode. Does not launch a second copy when already starting/running. | `{"appHostPath":"apphost.cs","mode":"run"}` | | `aspire_apphost_stop` | Stops that AppHost through the editor, or uses a path-targeted CLI stop for an externally started host. Never kills arbitrary processes. | `{"appHostPath":"apphost.cs"}` | Start also accepts `isolated` and an exact `launchProfile` name. Linked git worktrees default to isolation unless explicitly overridden. A `started` result means the launch was accepted, not that every resource is healthy; use status afterward. Targets must match discovered AppHosts in a trusted workspace. Arbitrary paths and commands are rejected. Results exclude raw logs, environment variables, process IDs, debug configurations, and authentication URLs. ## UI and returned data **Context for the inspection tools:** actual tool-started AppHost using locally built packages on `c9015d8`. Local paths and authentication URLs are redacted. The resource view itself is existing UI, not a new panel added by this PR.  **New Output tool:** consent opens a UI surface, not a channel-content response to the model. This crop is from the earlier real-editor E2E host.  <details> <summary>Actual responses from the new inspection and Dashboard tools</summary> These are recorded public-tool responses from the `c9015d8` playground, formatted for readability. The inspection tools return structured data rather than opening separate UI panels. ### List sessions Three editor-controlled AppHosts were running concurrently. Each keeps its own workspace-qualified identity: ```json { "success": true, "tool": "aspire_list_debug_sessions", "outcome": "sessionsFound", "sessions": [ { "appHost": "Lifecycle/apphost.cs", "state": "running", "mode": "run", "controller": "editor" }, { "appHost": "Two AppHosts/alpha/apphost.cs", "state": "running", "mode": "run", "controller": "editor" }, { "appHost": "Two AppHosts/beta/apphost.cs", "state": "running", "mode": "run", "controller": "editor" } ] } ``` ### Resource status The API is running and healthy. The result includes a safe source filename, not raw resource metadata: ```json { "success": true, "tool": "aspire_debug_session_status", "outcome": "running", "scope": "resource", "controller": "editor", "appHost": "Lifecycle/apphost.cs", "resourceName": "api", "resource": { "resourceType": "Project", "state": "Running", "healthStatus": "Healthy", "source": "PlaygroundApi.csproj" }, "mode": "run" } ``` ### Explain a failed launch The deliberately broken sample produced a recorded process-exit category and a fixed next action. The compiler text is not copied into the response: ```json { "success": true, "tool": "aspire_explain_launch_failure", "outcome": "failureFound", "appHost": "Intentional failure/apphost.cs", "stage": "cliLaunch", "category": "processExited", "controller": "cli", "mode": "run", "providerKind": "dotnet", "exitCodeBucket": "other", "recommendedActions": ["checkAspireOutput"] } ``` ### Hot Reload applicability Enabled does not mean applicable: C# Dev Kit and Hot Reload are enabled, but this resource was started without a debugger. The tool reports that distinction and suggests restarting the resource before rebuilding/restarting the AppHost: ```json { "success": true, "tool": "aspire_hot_reload_status", "outcome": "notApplicable", "appHost": "Lifecycle/apphost.cs", "resourceName": "api-akmnrnrd", "controller": "editor", "hotReloadEnabled": true, "evidence": [ "devKitInstalled", "hotReloadSettingEnabled", "hotReloadOnSaveEnabled", "editorSessionWithoutDebugger", "dotnetProjectResource" ], "fallback": ["restartResource", "rebuildAndRestartAppHost"] } ``` ### Dashboard handoff The recorded handoff used an external browser. The response reports the presentation without exposing a login URL: ```json { "success": true, "tool": "aspire_open_dashboard", "outcome": "opened", "presentation": "externalBrowser" } ``` </details> <details> <summary>Existing start/stop tools: lifecycle confirmation screenshots</summary> These are confirmations from the earlier real-editor E2E host for the existing lifecycle tools hardened by this PR. They do not establish current playground debug readiness. **Start:** the confirmation identifies the AppHost and requested mode.  **Stop:** confirmation is scoped to one AppHost.  </details> ## Follow-up fixes and verification Follow-up fixes preserve CLI-first startup failures, keep multi-root identities reusable, update MCP labels when ownership changes, and handle cancellation and synchronous spawn errors. Resource waits and confirmation expiry use monotonic time. Filesystem normalization handles caseless Unicode aliases and refuses to guess between conflicting entries. Tool registration and other shared helpers were extracted without a broader architecture refactor. Failure retention is now **one sanitized result per AppHost**, not a journal: 30-minute monotonic expiry, capped at 50 AppHosts. Removed history, sequence numbers, and record timestamps; shared the failure-mode mapping and safe-field projection instead of repeating them across producers and telemetry. Detailed errors stay in existing Output, CLI logs, and resource logs. No new log parser or diagnostics framework. - Current head `86ec1239a31e27dd17c3300fb71373c1863037b2`: **CI passed**, with no failed or pending checks at verification. [CI passed on attempt 2](https://github.com/microsoft/aspire/actions/runs/35685018093/attempts/2) after automatic failed-job retries. - **3,484 extension unit tests passed, with 5 existing pending tests**, plus TypeScript compilation, extension build, and lint. Independent review of the latest-failure simplification reported no findings. - A fresh local Git fixture produced a real CLI compilation failure. After all debug sessions were disposed, the public `vscode.lm.invokeTool` call still returned `failureFound`, without the raw compiler marker or absolute workspace path. - Earlier real-editor coverage exercised lifecycle, linked worktrees, multiple AppHosts, failure reporting, Dashboard/Output handoff, and Hot Reload applicability. The media and transcripts above retain their original source revisions; subsequent corrections have regression coverage and current-head CI. - The persistent DevDrive playground is verified in run mode. Debug startup stalls in its local C# setup, so active debugging/Hot Reload were not re-verified there. All **56 review threads are resolved**. The latest automated review reports no concrete finding but requests final human review of the broader lifecycle and process-control changes. This remains a draft; it has not been approved or merged. Fixes microsoft/aspire#19460 --------- Co-authored-by: Adam Ratzman <adamint@github.com> Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: Ella Hathaway <ellahathaway@microsoft.com> Copilot-Session: 2b9501ad-f5ba-4bc8-a7c2-ccdfaf15061c Copilot-Session: e3c8fa3a-d5fd-427d-baa5-3d0c1334a513 Copilot-Session: 466da694-ac7b-4ade-b31d-87ab0b2f01d5 Copilot-Session: 5f86d17d-2d6c-40a0-ac7f-c868300a1028 Copilot-Session: 05d72396-1499-4b53-b4bd-12ec6ff4844a Copilot-Session: bbc482ac-5a81-4feb-adac-5bd1cb982231 Copilot-Session: 7c01c030-226e-41c5-81ca-a6483a1856df Copilot-Session: ec9ccee5-689b-492b-817c-f86cea3afb16Adam Ratzman · f2528c52 · 2026-10-06
- 24.1ETVAdd AppHost terminals, dashboard docking, and terminal automation (#19887) Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: James Newton-King <james@newtonking.com> Copilot-Session: 3de8011a-08b4-48c9-aa13-f0feef9a378c Copilot-Session: 395e0f6a-f4c1-4db8-a3dd-e0fbf5392773 Copilot-Session: 6019354f-1f14-4f5b-9068-1179bc66b58eMitch Denny · a21e9394 · 2026-09-18
- 22.5ETVReplace CI failure analysis scripts with a typed analyzer (#21347) ## Description The existing CI failure-analysis agent workflow spreads collection, validation, and publication across shell scripts, inline Bash, and extensive `jq` expressions. That makes it difficult to understand the data flow, debug failures, or review whether a proposed analysis can safely update history and issues. This PR replaces that logic with the C# tool `AnalyzeCiFailure`. The workflow calls explicit commands; typed evidence and proposal contracts, validation, rendering, and publication policy live in testable C# code. ### Tool surface Run commands with: ```bash dotnet run --project tools/AnalyzeCiFailure/AnalyzeCiFailure.csproj --configuration Release -- <command> ``` | Command | What it does | Required arguments | |---|---|---| | `collect` | Fetch run/job metadata, logs, annotations, test artifacts, and prior cause history; generate evidence and diagnosis context. | `--repo`, `--run-id` | | `replay` | Regenerate diagnosis views from captured evidence without contacting GitHub. | `--evidence-dir` | | `validate` | Check an agent proposal against the independently collected evidence, without publication. | `--repo`, `--evidence-dir`, `--analysis-dir` | | `publish` | Validate again, check fresh history and issue destinations, then publish history, issues, and applicable PR comments. | `--repo`, `--evidence-dir`, `--analysis-dir` | | `workflow check-completion` | Check collection/publication job results for an accepted terminal outcome. Alias: `workflow require-publication`. | Reads workflow result environment variables. | | `workflow rerun` | Validate the proposal and fresh run/PR state before authorizing a rerun. | `--repo`, `--evidence-dir`, `--analysis-dir` | - `collect --run-attempt` pins an attempt; omission selects the latest attempt. - `--working-dir` selects the checkout used for relative paths and subprocesses; it defaults to the current directory. - `--github-output` writes Actions step outputs for `collect`, `replay`, and `publish`; it does not select the evidence directory. - `publish --history-dir` selects a new history checkout; the default is a private temporary directory. `--observed-at` defaults to the current UTC time. ### Workflow sequence ```text collect → evidence artifact → agent proposal → publish → check-completion ``` 1. **Collect:** a trusted sparse checkout runs `collect`. Available evidence is retained even when another artifact cannot be acquired. Unexplained missing required results produce a limited-evidence report and block publication. 2. **Diagnose:** when evidence is ready, the agent reads the prepared context and writes only a decision proposal. It does not construct authoritative evidence or choose issue destinations. 3. **Publish:** a separate trusted checkout downloads evidence independently of the proposal. `publish` validates their relationship, preflights destinations, records occurrences, updates issues/comments, and records resulting issue links. 4. **Check completion:** `workflow check-completion` rejects unhandled relevant failures. A successfully written limited-evidence report is an accepted non-publication outcome. 5. **Retain diagnostics:** collection and publication upload bounded progress, decision, and recovery artifacts. Operational reports link to the inspected source CI run. `replay` and `validate` support local investigation without publication. The rerun path uses `workflow rerun`, but rerun effects are disabled in this workflow. ### Fixes included - Main-scope publication omits the optional `pr_numbers` input instead of sending an empty value that the safe-output tool rejects. - Missing or malformed artifacts no longer discard unrelated captured failures; confirmed runner loss is distinguished from unexplained evidence gaps. - Mocha hook/harness errors remain diagnostic context without hiding completed assertion failures or inventing failed-test references. - More than ten independent causes produce one aggregate run-level issue while retaining individual cause history. - Secret redaction handles long setting prefixes without quadratic backtracking. Hook-heavy reports stop reprocessing diagnostic text after the per-job cap, count omissions, and continue collecting completed failures. - Sparse-bootstrap verification checks generated replay output; Windows executable lookup handles `.exe`; durable execution IDs are redacted and bounded. ### Validation - Analyzer suite — **1,168 passed**: ```bash MSBUILDTERMINALLOGGER=false ./.dotnet/dotnet test --project tests/AnalyzeCiFailure.Tests/AnalyzeCiFailure.Tests.csproj --no-launch-profile -- --filter-not-trait 'quarantined=true' --filter-not-trait 'outerloop=true' ``` - Release analyzer build — **passed, zero warnings/errors**: ```bash MSBUILDTERMINALLOGGER=false ./.dotnet/dotnet build tools/AnalyzeCiFailure/AnalyzeCiFailure.csproj --configuration Release --no-restore ``` - Workflow infrastructure: **771 passed**; test-selection routing: **366 passed**. - Pinned `gh-aw` v0.89.17 compilation reproduced the committed workflow twice. - Historical hosted validation used read-only profiles; publication previews intercepted mutations. Production issue creation and rerun effects were not exercised by those runs. ### Security considerations The tool processes untrusted CI logs, archives, and agent proposals before privileged history/issue updates. Trusted checkouts, independent evidence transfer, exact coverage/provenance checks, bounded extraction, redaction, and fresh destination checks enforce those boundaries. Structural validation does not prove the agent's causal diagnosis is correct. ### Issues fixed - Grouped flaky causes now validate each current observation without requiring a combined legacy `test_name` to equal one individual test. Fixes #20332. - Cause issues and occurrence rows use their associated jobs rather than the first failed job in the run. Fixes #19881. Main-scope `publish_data` calls no longer require a fabricated or empty PR number: `pr_numbers` is optional and omitted when there is no subject PR. This addresses the same reported input-validation failure in: Fixes #21415 Fixes #21339 Fixes #21312 Fixes #21293 Fixes #21257 Fixes #21224 Fixes #21016 Fixes #20587 ### Related work remaining open - #19578: the complete prior-cause catalogue addresses context availability, but inconsistent semantic cause reuse remains unresolved. - #21467: recurring operational issue tracking for incomplete evidence. - #21468: publication support for hook-only and log-only job failures. - #21469: structured results inside oversized diagnostic archives. - #21470: consistent grouping of identical shared-fixture failures. ## Checklist - Is this feature complete? - [ ] Yes. Ready to ship. - [x] 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? - [ ] Yes - If yes, did you have an API Review for it? - [ ] Yes - [ ] No - Did you add `<remarks />` and `<code />` elements on your triple slash comments? - [ ] Yes - [ ] No - [x] No - Does the change make any security assumptions or guarantees? - [x] Yes - If yes, have you done a threat model and had a security review? - [ ] Yes - [x] No - [ ] No --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>Ankit Jain · 8d79e4e4 · 2026-11-03
- 16.8ETVMigrate dashboard to Fluent UI Blazor v5 (#19431)James Newton-King · 62028348 · 2026-09-09
- 16.6ETVStandardize NuGet restore and channel-update policy across AppHosts (#19763) ## Description Polyglot integration restore, package/template discovery, and C# channel updates currently compose NuGet policy in different ways. This can make the packages offered by discovery disagree with what can be restored, change configuration behavior when an integration project reference is added, or leave persisted AppHost configuration inconsistent with an update. This PR shares NuGet configuration composition across those paths. Aspire-selected sources and mappings are applied alongside NuGet's native configuration hierarchy, reusing existing source aliases and inheriting their authentication and transport settings. Package and project integrations resolve together, discovery checks source eligibility, and explicit C# channel updates preview configuration changes before restoring and persisting them. ### Polyglot integration restore - Package-only AppHosts restore all integration packages through the CLI's in-process NuGet client without requiring the .NET SDK. - AppHosts with project references use one generated `IntegrationRestore.csproj` containing the direct integration packages and projects. NuGet resolves their shared dependency graph and reports incompatible requirements during restore. - The generated root targets the current host runtime identifier. Referenced projects retain their own target and restore behavior. Package assets remain in NuGet package folders; project-built output is copied into a content-addressed snapshot. Configuration discovery is anchored at the AppHost rather than the generated cache directory. Both restore implementations use the same selected SDK, channel, source override, and evaluated NuGet settings. Overlays express the selected source/mapping policy; operations requiring a separate package cache use one instead of the ordinary global-packages folder. Referenced projects continue to discover configuration from their own directories. Opt-in MSBuild properties provide hosting-version and credential-free source hints without automatically replacing the projects' restore configuration. ### Integration and template discovery Bundled and SDK-driven discovery check effective package-source mappings before offering ordinary search or exact-version results. Bundled discovery filters before cross-source deduplication so an ineligible feed's higher version cannot hide an eligible result. An explicit `--source` restricts discovery and template installation to that source while retaining an existing selected alias's NuGet settings. Dependency restore has a different scope: after polyglot `aspire add` selects a package, its package ID is mapped to the explicit source, but other eligible sources remain available for dependencies. The selected integration feed is not assumed to contain every dependency. ### C# AppHost updates Unqualified updates preserve the current native NuGet policy rather than selecting replacement feeds from CLI or Aspire channel metadata. Explicit channel updates compose a configuration candidate and show it through the existing NuGet preview and approval flow. Project/package edits are staged, the updated graph is restored through native MSBuild, and configuration and metadata changes are persisted only after restore succeeds. Handled failures roll back owned file edits. An unresolved AppHost SDK can be repaired before strict restore-policy validation, without allowing unknown or overridden policy to be persisted. Fallback project parsing also normalizes MSBuild project-reference separators across platforms. When an existing mapping policy is Aspire-only, the candidate can add `*` mappings for enabled, previously unmapped ambient feeds so unrelated dependencies remain eligible. These mapping changes appear in the same approval; inherited feed URLs and credentials are not copied into the local file. Unrelated mapping restrictions are retained. Explicit stable selection returns to existing ambient feeds without adding NuGet.org; an explicitly supplied service-index override remains a separate source selection. ### Known trade-offs - `aspire add` does not persist per-integration channel or source provenance. A package selected from another channel or an explicit source can restore for that invocation but require a project-wide channel change or user-owned NuGet configuration for a later cold restore. - The project-reference path always runs implicit restore before building the generated integration project. It favors correctness over warm-build performance; package-only restores retain their reusable cache. - Package-only restores do not fully support NuGet fallback package folders from configuration or `NUGET_FALLBACK_PACKAGES`. Manifest asset resolution across those folders remains tracked by #20631. ### NuGet configuration and diagnostics NuGet remains responsible for evaluating configuration and handling authentication and trust settings. Overlays reuse existing source aliases and leave those settings in their original hierarchy rather than copying them into generated configuration. Credential-bearing explicit `--source` values are rejected. For configured sources containing inline credentials, diagnostic handling suppresses raw invocation logging and applies best-effort redaction using known URL spellings and credential components. This is not a general-purpose credential scrubber. Generated NuGet artifacts are not scrubbed and can still contain configured source URLs; credential providers and credential sections remain preferred over inline URL credentials. Related: #20631 tracks the remaining fallback-package-folder limitation. ## Checklist - 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? - [ ] Yes - If yes, did you have an API Review for it? - [ ] Yes - [ ] No - Did you add `<remarks />` and `<code />` elements on your triple slash comments? - [ ] Yes - [ ] No - [x] 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: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: d38799a7-a99c-48c5-b45b-9d6594dd1830David Negstad · fff2b56e · 2026-10-15