Blog
Mert Özen's blog posts on software development, backend, frontend, and DevOps.
What Is Aspire and What Isn't It? AppHost, the App Model and How It Differs from Docker Compose and Kubernetes
Aspire is a local orchestration and observability layer that describes the parts of a multi-service app and their connections in code in an AppHost, runs them with one command and collects their telemetry in a dashboard; it isn't a production orchestrator or a service mesh. The post adds an AppHost to Bookstore with aspire init and shows the DCP proxy, the environment variables Aspire provides and why there are no traces without ServiceDefaults, with real output.
Orchestration with the AppHost: Resources, WithReference, WaitFor, Parameters and Persistent Containers
In the AppHost every part is a resource: a project, a container or an executable; WithReference passes connection strings and connection properties as environment variables, WaitFor waits for health and WaitForCompletion for a job to exit with code 0. The post adds SQL Server, Redis and a migration worker to Bookstore and shows, with real output, the trap of a throwing worker exiting with code 0 and starting the API, secret parameters and persistent containers.
Service Discovery and ServiceDefaults: How "https+http://catalog" Resolves and What the Defaults Do
The address "https+http://catalog" resolves through the Services:catalog configuration read from the services__catalog__http__0 variable Aspire provides; with no entry the name is left to DNS, so the same code works in production. The post shows the resolution logs, that the template's AllowedSchemes comment does nothing unless AllowAllSchemes is turned off, what ServiceDefaults contains, cutting a 30-second wait for a stopped service to 5 seconds, and a YARP gateway, with real output.
The Aspire Dashboard: Reading Logs, Traces and Metrics, Standalone Use and Telemetry Persistence
The Aspire dashboard is a development tool that shows the logs, traces and metrics services send over OTLP in one place; since 13.6 it stores every run in SQLite and it also runs standalone without Aspire, but it isn't a production observability tool. The post finds an unindexed EF Core query and sequential service calls in a slow order's waterfall and cuts it from 69 ms to 5 ms, and shows aspire otel, export and a standalone dashboard with an API key, with real output.
Aspire Integrations: Hosting and Client Integrations, SQL Server, Redis, RabbitMQ, Keycloak and Your Own Resource
A hosting integration models the resource in the AppHost; a client integration registers the client library in the service with a health check, telemetry and retries, and those defaults don't suit every dependency. The post fixes the settings that made the catalog wait 12 seconds and go unhealthy without Redis, traces an order event and its consumer span with RabbitMQ, protects a back office endpoint with Keycloak and adds a dashboard command.
Testing with Aspire: End-to-End Tests That Start the Whole System with Aspire.Hosting.Testing
Aspire.Hosting.Testing really starts the AppHost in a test fixture and hands out HttpClients for resources; it suits a few critical end-to-end scenarios and doesn't replace in-service tests. The post keeps tests away from the developer's database, starts only the containers each scenario needs, shows the template's retry repeating a POST and causing a 409, and waits for an asynchronous confirmation by polling instead of Task.Delay, with real output.
Deploying with Aspire: publish, deploy and do; Docker Compose, Kubernetes and Azure Targets
aspire publish turns the AppHost into artifacts with placeholders (a Compose file, a Helm chart), aspire deploy resolves values, builds images and applies them, and aspire do runs a single pipeline step. Deploying Bookstore to Docker Compose, the post fixes a gateway that wasn't exposed, seed data leaking into production, a non-https Keycloak Authority and Angular's output folder, and covers the Helm chart, the registry requirement and Azure targets.
From .NET Aspire 8 to Aspire 13.6: Release History, Breaking Changes and Migrating an Old Project
Aspire moved from the workload and manifest model of 8.0 to the SDK in 9.x and to the rename, the .NET 10 requirement and pipelines in 13.0; every 13.x minor release brings its own breaking changes. The post summarizes the release line and migrates a project written with Aspire 9.5 to 13.6 with aspire update, showing with real output what the command leaves undone (net10.0, AddNpmApp, the lifecycle hook, the launch profile).