BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News .NET Aspire - Preview 2: Improvements for Dashboard, Hosting, Components, Dapr, and More

.NET Aspire - Preview 2: Improvements for Dashboard, Hosting, Components, Dapr, and More

This item in japanese

Last week, Microsoft revealed the availability of the .NET Aspire - second preview. Preview 2 brings changes and improvements regarding the dashboard, hosting, components, Dapr and many more. The .NET Aspire is a new cloud-native development stack announced by Microsoft and the .NET team back in November during the .NET Conf Event.

For readers who are not familiar, the .NET Aspire is an opinionated stack that enables developers and teams to build, provision, deploy, configure, test, run, and observe cloud applications easily. It is a new and cloud-native development stack for building resilient, observable, and configurable cloud-native applications within the dotnet ecosystem.

.NET Aspire includes a selected set of components enhanced for cloud-native by including service discovery, telemetry, resilience, and health checks by default.
More details about the initial release can be read in InfoQ coverage of .NET Aspire.

Preview 2 brings a lot of improvements, regarding the dashboard, it has undergone significant improvements, consolidating all resource types such as details of the projects, executables, and containers into a unified Resources page in Preview 2 of the Aspire dashboard.

(.NET Aspire Dashboard, a new Resources page, Source: Announcing .NET Aspire Preview 2)

Continuing, a new dockable details pane design enhances user experience, providing a more intuitive interface to show more information for relevant items, like the environment variables for a resource, or the details of a structured log or tracing span.

Additionally, console logs for various resource types are now accessible through a single Console Logs page. Within the Structured Logs view, the log category name is now included for better categorization. Notably, outgoing requests to other resources and development services are now displayed with the resource or service name instead of the URL, enhancing clarity and traceability.

On the other hand, there are improvements for hosting and orchestration, containers now offer support for configuring arguments to be passed during startup using IResourceBuilder<ContainerResource>.WithArgs method.

Furthermore, both containers and executables can reference other resources through endpoints, enabling service discovery configuration using the WithServiceBinding method. Also, the ability to add projects without a <ProjectReference /> has been introduced, providing flexibility in project structuring.

Damian Edwards stated the following in the original announcement post:

This can make it easier to integrate projects from outside of the current solution in more complex source layout situations, e.g. when using git submodules to bring in the contents of partner team repos. 

Resources are now capable of referencing existing URI endpoints for service discovery configuration. Notably, projects now utilize the port from their launch profile when hosted, whether with or without replicas, and the update introduces support for adding Node.js apps as resources.

Node.js apps can be simply included in an Aspire AppHost project using the AddNodeApp and AddNpmApp methods. This built-in support is now utilised in the new Aspire with Node.js sample, which also shows how to set up the Node.js application to egress OpenTelemetry traces to the Aspire dashboard.

Component packages receive individual icons for improved visual identification. Noteworthy additions there is an addition of the MySqlConnector and MongoDB components. Additionally, Azure SDK components now come with distributed tracing enabled by default, excluding Service Bus components.

(Aspire components now have representative icons, Source: Announcing .NET Aspire Preview 2)

The Azure Developer CLI has experienced improvements to improve the deployment experience. An important addition is Aspir8, a community-developed tool specifically designed for deploying .NET Aspire apps to Kubernetes, developed by a GitHub user named prom3theu5.

Dapr integration sees notable improvements in this release. Preview 2 introduces first-class support for Dapr all components in the app model, enhancing the overall development experience. IDs for Dapr sidecars no longer require explicit specification, simplifying configuration, however, developers can still explicitly set the application ID to an explicit value, if desired.

Moreover, the Azure Developer CLI (AZD) now supports the deployment of .NET Aspire apps utilizing Dapr to Azure Container Apps (ACA), as reported, the team is working to ensure that azd enables the fastest and simplest way to get an Aspire app provisioned and deployed to Azure in minutes, and it is stated that the Preview 2 release primarily targets Azure Container Apps.

Lastly, regarding the future .NET Aspire team comments that they plan to release a new preview version each month, leading up to a stable 8.0 release in the second quarter of 2024. This monthly release rhythm aims to provide developers with regular updates, introducing new features and optimizations.

About the Author

Rate this Article

Adoption
Style

BT