diff --git a/docs/caching/caching-components-deployment.md b/docs/caching/caching-components-deployment.md index 60e68fb7b..c3d8f4667 100644 --- a/docs/caching/caching-components-deployment.md +++ b/docs/caching/caching-components-deployment.md @@ -1,13 +1,13 @@ --- -title: Deploy a .NET Aspire app that connects to Redis Cache to Azure -description: Learn how to deploy a .NET Aspire app that connects to Redis Cache to Azure +title: Deploy a .NET Aspire project that connects to Redis Cache to Azure +description: Learn how to deploy a .NET Aspire project that connects to Redis Cache to Azure ms.date: 06/11/2024 ms.topic: how-to --- -# Tutorial: Deploy a .NET Aspire app with a Redis Cache to Azure +# Tutorial: Deploy a .NET Aspire project with a Redis Cache to Azure -In this tutorial, you learn to configure a .NET Aspire app with a Redis Cache for deployment to Azure. .NET Aspire provides multiple caching component configurations that provision different Redis services in Azure. You'll learn how to: +In this tutorial, you learn to configure a .NET Aspire project with a Redis Cache for deployment to Azure. .NET Aspire provides multiple caching component configurations that provision different Redis services in Azure. You'll learn how to: > [!div class="checklist"] > @@ -108,7 +108,7 @@ The preceding code adds a Redis Container resource to your app and configures a Tools such as the [Azure Developer CLI](/azure/developer/azure-developer-cli/overview) (`azd`) support .NET Aspire Redis component configurations to streamline deployments. `azd` consumes these settings and provisions properly configured resources for you. > [!NOTE] -> You can also use the [Azure CLI](/dotnet/aspire/deployment/azure/aca-deployment?pivots=azure-cli) or [Bicep](/dotnet/aspire/deployment/azure/aca-deployment?pivots=azure-bicep) to provision and deploy .NET Aspire app resources. These options require more manual steps, but provide more granular control over your deployments. .NET Aspire apps can also connect to an existing Redis instance through manual configurations. +> You can also use the [Azure CLI](/dotnet/aspire/deployment/azure/aca-deployment?pivots=azure-cli) or [Bicep](/dotnet/aspire/deployment/azure/aca-deployment?pivots=azure-bicep) to provision and deploy .NET Aspire project resources. These options require more manual steps, but provide more granular control over your deployments. .NET Aspire projects can also connect to an existing Redis instance through manual configurations. 1. Open a terminal window in the root of your .NET Aspire project. @@ -154,4 +154,4 @@ The deployment process created a Redis app container due to the **.AppHost** con - [.NET Aspire deployment via Azure Container Apps](../deployment/azure/aca-deployment.md) - [.NET Aspire Azure Container Apps deployment deep dive](../deployment/azure/aca-deployment-azd-in-depth.md) -- [Deploy a .NET Aspire app using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) +- [Deploy a .NET Aspire project using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) diff --git a/docs/caching/stackexchange-redis-caching-overview.md b/docs/caching/stackexchange-redis-caching-overview.md index 08af918d1..242a46457 100644 --- a/docs/caching/stackexchange-redis-caching-overview.md +++ b/docs/caching/stackexchange-redis-caching-overview.md @@ -8,7 +8,7 @@ ms.date: 06/11/2024 With .NET Aspire, there are several ways to use caching in your applications. One popular option is to use [Stack Exchange Redis](https://stackexchange.github.io/StackExchange.Redis), which is a high-performance data store that can be used to store frequently accessed data. This article provides an overview of Stack Exchange Redis caching and links to resources that help you use it in your applications. -To use multiple Redis caching components in your application, see [Tutorial: Implement caching with .NET Aspire components](caching-components.md). If you're interested in using the Redis Cache for Azure, see [Tutorial: Deploy a .NET Aspire app with a Redis Cache to Azure](caching-components-deployment.md). +To use multiple Redis caching components in your application, see [Tutorial: Implement caching with .NET Aspire components](caching-components.md). If you're interested in using the Redis Cache for Azure, see [Tutorial: Deploy a .NET Aspire project with a Redis Cache to Azure](caching-components-deployment.md). ## Caching diff --git a/docs/database/ef-core-migrations.md b/docs/database/ef-core-migrations.md index 5d4b4427b..c81151568 100644 --- a/docs/database/ef-core-migrations.md +++ b/docs/database/ef-core-migrations.md @@ -7,9 +7,9 @@ ms.topic: how-to # Apply Entity Framework Core migrations in .NET Aspire -Since .NET Aspire apps use a containerized architecture, databases are ephemeral and can be recreated at any time. Entity Framework Core (EF Core) uses a feature called [migrations](/ef/core/managing-schemas/migrations) to create and update database schemas. Since databases are recreated when the app starts, you need to apply migrations to initialize the database schema each time your app starts. This is accomplished by registering a migration service project in your app that runs migrations during startup. +Since .NET Aspire projects use a containerized architecture, databases are ephemeral and can be recreated at any time. Entity Framework Core (EF Core) uses a feature called [migrations](/ef/core/managing-schemas/migrations) to create and update database schemas. Since databases are recreated when the app starts, you need to apply migrations to initialize the database schema each time your app starts. This is accomplished by registering a migration service project in your app that runs migrations during startup. -In this tutorial, you learn how to configure .NET Aspire apps to run EF Core migrations during app startup. +In this tutorial, you learn how to configure .NET Aspire projects to run EF Core migrations during app startup. [!INCLUDE [aspire-prereqs](../includes/aspire-prereqs.md)] diff --git a/docs/database/seed-database-data.md b/docs/database/seed-database-data.md index cadfe856f..db83dabc9 100644 --- a/docs/database/seed-database-data.md +++ b/docs/database/seed-database-data.md @@ -7,7 +7,7 @@ ms.topic: how-to # Seed data in a database using .NET Aspire -In this article, you learn how to configure .NET Aspire apps to seed data in a database during app startup. .NET Aspire enables you to seed data using database scripts or Entity Framework Core for common platforms such as SQL Server, PostgreSQL and MySQL. +In this article, you learn how to configure .NET Aspire projects to seed data in a database during app startup. .NET Aspire enables you to seed data using database scripts or Entity Framework Core for common platforms such as SQL Server, PostgreSQL and MySQL. ## When to seed data @@ -16,7 +16,7 @@ Seeding data pre-populates database tables with rows of data so they're ready fo - Manually develop and test different features of your app against a meaningful set of data, such as a product catalog or list of customers. - Run test suites to verify that features behave a specific way with a given set of data. -Manually seeding data is tedious and time consuming, so you should automate the process when possible. Use volumes to run database scripts for .NET Aspire apps during startup. You can also seed your database using tools like Entity Framework Core, which handles many underlying concerns for you. +Manually seeding data is tedious and time consuming, so you should automate the process when possible. Use volumes to run database scripts for .NET Aspire projects during startup. You can also seed your database using tools like Entity Framework Core, which handles many underlying concerns for you. ## Understand containerized databases @@ -121,7 +121,7 @@ Corresponding SQL script included in the app: ## Seed data using Entity Framework Core -You can also seed data in .NET Aspire apps using Entity Framework Core by explicitly running migrations during startup. Entity Framework Core handles underlying database connections and schema creation for you, which eliminates the need to use volumes or run SQL scripts during container startup. +You can also seed data in .NET Aspire projects using Entity Framework Core by explicitly running migrations during startup. Entity Framework Core handles underlying database connections and schema creation for you, which eliminates the need to use volumes or run SQL scripts during container startup. > [!IMPORTANT] > These types of configurations should only be done during development, so make sure to add a conditional that checks your current environment context. diff --git a/docs/database/sql-server-component-deployment.md b/docs/database/sql-server-component-deployment.md index 3c2560f09..3a1b23682 100644 --- a/docs/database/sql-server-component-deployment.md +++ b/docs/database/sql-server-component-deployment.md @@ -5,7 +5,7 @@ ms.date: 05/14/2024 ms.topic: how-to --- -# Tutorial: Deploy a .NET Aspire app with a SQL Server Database to Azure +# Tutorial: Deploy a .NET Aspire project with a SQL Server Database to Azure In this tutorial, you learn to configure an ASP.NET Core app with a SQL Server Database for deployment to Azure. .NET Aspire provides multiple SQL Server component configurations that provision different database services in Azure. You'll learn how to: @@ -41,7 +41,7 @@ Visual Studio creates a new ASP.NET Core solution that is structured to use .NET ## [.NET CLI](#tab/cli) -In an empty directory, run the following command to create a new .NET Aspire app: +In an empty directory, run the following command to create a new .NET Aspire project: ```dotnetcli dotnet new aspire-starter --output AspireSql @@ -135,4 +135,4 @@ The deployment process created a SQL Server app container due to the **.AppHost* - [.NET Aspire deployment via Azure Container Apps](../deployment/azure/aca-deployment.md) - [.NET Aspire Azure Container Apps deployment deep dive](../deployment/azure/aca-deployment-azd-in-depth.md) -- [Deploy a .NET Aspire app using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) +- [Deploy a .NET Aspire project using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) diff --git a/docs/database/sql-server-components.md b/docs/database/sql-server-components.md index e39f1762c..87b5c5bf3 100644 --- a/docs/database/sql-server-components.md +++ b/docs/database/sql-server-components.md @@ -104,7 +104,7 @@ The preceding code adds a SQL Server Container resource to your app and configur The sample app is now ready for testing. Verify that the submitted form data is persisted to the database by completing the following steps: -1. Select the run button at the top of Visual Studio (or F5) to launch your .NET Aspire app dashboard in the browser. +1. Select the run button at the top of Visual Studio (or F5) to launch your .NET Aspire project dashboard in the browser. 1. On the projects page, in the **AspireSQLEFCore** row, click the link in the **Endpoints** column to open the UI of your app. :::image type="content" source="media/app-home-screen.png" lightbox="media/app-home-screen.png" alt-text="A screenshot showing the home page of the .NET Aspire support application."::: @@ -117,4 +117,4 @@ The sample app is now ready for testing. Verify that the submitted form data is - [.NET Aspire with SQL Database deployment](sql-server-component-deployment.md) - [.NET Aspire deployment via Azure Container Apps](../deployment/azure/aca-deployment.md) -- [Deploy a .NET Aspire app using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) +- [Deploy a .NET Aspire project using GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) diff --git a/docs/deployment/azure/aca-deployment-azd-in-depth.md b/docs/deployment/azure/aca-deployment-azd-in-depth.md index c45adb3f0..9c7a2cdbf 100644 --- a/docs/deployment/azure/aca-deployment-azd-in-depth.md +++ b/docs/deployment/azure/aca-deployment-azd-in-depth.md @@ -1,18 +1,18 @@ --- -title: Deploy a .NET Aspire app to Azure Container Apps using `azd` (in-depth guide) -description: Learn how to use `azd` to deploy .NET Aspire apps to Azure Container Apps. +title: Deploy a .NET Aspire project to Azure Container Apps using `azd` (in-depth guide) +description: Learn how to use `azd` to deploy .NET Aspire projects to Azure Container Apps. ms.date: 03/08/2024 ms.custom: devx-track-extended-azdevcli --- -# Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide) +# Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide) -The Azure Developer CLI (`azd`) has been extended to support deploying .NET Aspire applications. Use this guide to walk through the process of creating and deploying a .NET Aspire application to Azure Container Apps using the Azure Developer CLI. In this tutorial, you'll learn the following concepts: +The Azure Developer CLI (`azd`) has been extended to support deploying .NET Aspire projects. Use this guide to walk through the process of creating and deploying a .NET Aspire project to Azure Container Apps using the Azure Developer CLI. In this tutorial, you'll learn the following concepts: > [!div class="checklist"] > -> - Explore how `azd` integration works with .NET Aspire apps -> - Provision and deploy resources on Azure for a .NET Aspire app using `azd` +> - Explore how `azd` integration works with .NET Aspire projects +> - Provision and deploy resources on Azure for a .NET Aspire project using `azd` > - Generate Bicep infrastructure and other template files using `azd` [!INCLUDE [aspire-prereqs](../../includes/aspire-prereqs.md)] @@ -43,9 +43,9 @@ curl -fsSL https://aka.ms/install-azd.sh | bash The `azd init` workflow provides customized supported for .NET Aspire projects. The following diagram illustrates how this flow works conceptually and how `azd` and .NET Aspire are integrated: -:::image type="content" source="media/azd-internals.png" alt-text="Illustration of internal processing of `azd` when deploying .NET Aspire application."::: +:::image type="content" source="media/azd-internals.png" alt-text="Illustration of internal processing of `azd` when deploying .NET Aspire project."::: -1. When `azd` targets a .NET Aspire application it starts the AppHost with a special command (`dotnet run --project AppHost.csproj --output-path manifest.json --publisher manifest`), which produces the Aspire [manifest file](../manifest-format.md). +1. When `azd` targets a .NET Aspire project it starts the AppHost with a special command (`dotnet run --project AppHost.csproj --output-path manifest.json --publisher manifest`), which produces the Aspire [manifest file](../manifest-format.md). 1. The manifest file is interrogated by the `azd provision` sub-command logic to generate Bicep files in-memory only (by default). 1. After generating the Bicep files, a deployment is triggered using Azure's ARM APIs targeting the subscription and resource group provided earlier. 1. Once the underlying Azure resources are configured, the `azd deploy` sub-command logic is executed which uses the same Aspire manifest file. @@ -62,7 +62,7 @@ The steps in this section demonstrate how to create a .NET Aspire start app and ### Create the .NET Aspire starter app -Create a new .NET Aspire application using the `dotnet new` command. You can also create the project using Visual Studio. +Create a new .NET Aspire project using the `dotnet new` command. You can also create the project using Visual Studio. ```dotnetcli dotnet new aspire-starter --use-redis-cache -o AspireSample @@ -70,7 +70,7 @@ cd AspireSample dotnet run --project AspireSample.AppHost\AspireSample.AppHost.csproj ``` -The previous commands create a new .NET Aspire application based on the `aspire-starter` template which includes a dependency on Redis cache. It runs the .NET Aspire project which verifies that everything is working correctly. +The previous commands create a new .NET Aspire project based on the `aspire-starter` template which includes a dependency on Redis cache. It runs the .NET Aspire project which verifies that everything is working correctly. [!INCLUDE [init workflow](includes/init-workflow.md)] @@ -89,7 +89,7 @@ services: ### Initial deployment -1. In order to deploy the .NET Aspire application, authenticate to Azure AD to call the Azure resource management APIs. +1. In order to deploy the .NET Aspire project, authenticate to Azure AD to call the Azure resource management APIs. ```azdeveloper azd auth login @@ -106,7 +106,7 @@ services: > [!IMPORTANT] > To push container images to the Azure Container Registry (ACR), you need to have `Microsoft.Authorization/roleAssignments/write` access. This can be achieved by enabling an **Admin user** on the registry. Open the Azure Portal, navigate to the ACR resource / Settings / Access keys, and then select the **Admin user** checkbox. For more information, see [Enable admin user](/azure/container-registry/container-registry-authentication#admin-account). -1. When prompted, select the subscription and location the resources should be deployed to. Once these options are selected the .NET Aspire application +1. When prompted, select the subscription and location the resources should be deployed to. Once these options are selected the .NET Aspire project will be deployed. [!INCLUDE [azd-up-output](includes/azd-up-output.md)] @@ -126,12 +126,12 @@ Just like in local development, the configuration of connection strings has been :::image type="content" loc-scope="azure" source="media/azd-aca-variables.png" lightbox="media/azd-aca-variables.png" alt-text="A screenshot of environment variables in the webfrontend container app."::: -For more information on how .NET Aspire apps handle connection strings and service discovery, see +For more information on how .NET Aspire projects handle connection strings and service discovery, see [.NET Aspire orchestration overview](../../fundamentals/app-host-overview.md). ### Deploy application updates -When the `azd up` command is executed the underlying Azure resources are _provisioned_ and a container image is built and _deployed_ to the container apps hosting the .NET Aspire app. Typically once development is underway and Azure resources are deployed it won't be necessary to provision Azure resources every time code is updated—this is especially true for the developer inner loop. +When the `azd up` command is executed the underlying Azure resources are _provisioned_ and a container image is built and _deployed_ to the container apps hosting the .NET Aspire project. Typically once development is underway and Azure resources are deployed it won't be necessary to provision Azure resources every time code is updated—this is especially true for the developer inner loop. To speed up deployment of code changes, `azd` supports deploying code updates in the container image. This is done using the `azd deploy` command: @@ -141,7 +141,7 @@ azd deploy [!INCLUDE [azd-deploy-output](includes/azd-deploy-output.md)] -It's not necessary to deploy all services each time. `azd` understands the .NET Aspire app model, it's possible to deploy just one of the services specified using the following command: +It's not necessary to deploy all services each time. `azd` understands the .NET Aspire project model, it's possible to deploy just one of the services specified using the following command: ```azdeveloper azd deploy webfrontend @@ -151,7 +151,7 @@ For more information, see [Azure Developer CLI reference: azd deploy](/azure/dev ### Deploy infrastructure updates -Whenever the dependency structure within a .NET Aspire app changes, `azd` must re-provision the underlying Azure resources. The `azd provision` command is used to apply these changes to the infrastructure. +Whenever the dependency structure within a .NET Aspire project changes, `azd` must re-provision the underlying Azure resources. The `azd provision` command is used to apply these changes to the infrastructure. To see this in action, update the _:::no-loc text="Program.cs":::_ file in the AppHost project to the following: @@ -194,7 +194,7 @@ The previous command may take some time to execute, but when completed the resou [!INCLUDE [azd-down-output](includes/azd-down-output.md)] -## Generate Bicep from .NET Aspire app model +## Generate Bicep from .NET Aspire project model Although development teams are free to use `azd up` (or `azd provision` and `azd deploy`) commands for their deployments both for development and production purposes, some teams may choose to generate Bicep files that they can review and manage as part of version control (this also allows these Bicep files to be referenced as part of a larger more complex Azure deployment). @@ -209,7 +209,7 @@ After this command is executed in the starter template example used in this guid - _infra/main.bicep_: Represents the main entry point for the deployment. - _infra/main.parameters.json_: Used as the parameters for main Bicep (maps to environment variables defined in _.azure_ folder). -- _infra/resoures.bicep_: Defines the Azure resources required to support the .NET Aspire app model. +- _infra/resoures.bicep_: Defines the Azure resources required to support the .NET Aspire project model. - _AspireSample.Web/manifests/containerApp.tmpl.yaml_: The container app definition for `webfrontend`. - _AspireSample.ApiService/manifests/containerApp.tmpl.yaml_: The container app definition for `apiservice`. diff --git a/docs/deployment/azure/aca-deployment-github-actions.md b/docs/deployment/azure/aca-deployment-github-actions.md index b745f5775..f83f4b416 100644 --- a/docs/deployment/azure/aca-deployment-github-actions.md +++ b/docs/deployment/azure/aca-deployment-github-actions.md @@ -1,19 +1,19 @@ --- -title: Deploy a .NET Aspire app using the Azure Developer CLI and GitHub Actions -description: Learn how to use `azd` and GitHub Actions to deploy .NET Aspire apps. +title: Deploy a .NET Aspire project using the Azure Developer CLI and GitHub Actions +description: Learn how to use `azd` and GitHub Actions to deploy .NET Aspire projects. ms.date: 05/30/2024 zone_pivot_groups: deployment-platform ms.custom: devx-track-extended-azdevcli --- -# Tutorial: Deploy a .NET Aspire app using the Azure Developer CLI and GitHub Actions +# Tutorial: Deploy a .NET Aspire project using the Azure Developer CLI and GitHub Actions -The Azure Developer CLI (`azd`) enables you to deploy .NET Aspire applications using GitHub Actions by automatically configuring the required authentication and environment settings. This article walks you through the process of creating and deploying a .NET Aspire app on Azure Container Apps using `azd` and GitHub Actions. You learn the following concepts: +The Azure Developer CLI (`azd`) enables you to deploy .NET Aspire projects using GitHub Actions by automatically configuring the required authentication and environment settings. This article walks you through the process of creating and deploying a .NET Aspire project on Azure Container Apps using `azd` and GitHub Actions. You learn the following concepts: > [!div class="checklist"] > -> - Explore how `azd` integration works with .NET Aspire apps and GitHub Actions -> - Create and configure a GitHub repository for a .NET Aspire app using `azd` +> - Explore how `azd` integration works with .NET Aspire projects and GitHub Actions +> - Create and configure a GitHub repository for a .NET Aspire project using `azd` > - Add a GitHub Actions workflow file to your .NET Aspire solution > - Monitor and explore GitHub Actions workflow executions and Azure deployments @@ -54,9 +54,9 @@ curl -fsSL https://aka.ms/install-azd.sh | bash --- -## Create a .NET Aspire app +## Create a .NET Aspire project -As a starting point, this article assumes that you've created a .NET Aspire app from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire app](../../get-started/build-your-first-aspire-app.md). +As a starting point, this article assumes that you've created a .NET Aspire project from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire project](../../get-started/build-your-first-aspire-app.md). [!INCLUDE [init workflow](includes/init-workflow.md)] @@ -181,7 +181,7 @@ The Azure Developer CLI enables you to automatically create CI/CD pipelines with :::image type="content" loc-scope="github" source="media/deployment-links.png" alt-text="A screenshot showing the deployed app links."::: -Congratulations! You successfully deployed a .NET Aspire app using the Azure Developer CLI and GitHub Actions. +Congratulations! You successfully deployed a .NET Aspire project using the Azure Developer CLI and GitHub Actions. :::zone-end @@ -316,7 +316,7 @@ The Azure Developer CLI enables you to automatically create pipelines with the c > [!IMPORTANT] > If you encounter a `403 Forbidden` error when viewing your site in the browser, make sure the ingress settings are configured correctly. On the **webfrontend** app page in the Azure Portal, navigate to **Ingress** on the left navigation. Make sure **Ingress traffic** is set to **Accepting traffic from anywhere** and save your changes. -Congratulations! You successfully deployed a .NET Aspire app using the Azure Developer CLI and Azure Pipelines. +Congratulations! You successfully deployed a .NET Aspire project using the Azure Developer CLI and Azure Pipelines. :::zone-end diff --git a/docs/deployment/azure/aca-deployment-visual-studio.md b/docs/deployment/azure/aca-deployment-visual-studio.md index 8159a3466..21c13d1d5 100644 --- a/docs/deployment/azure/aca-deployment-visual-studio.md +++ b/docs/deployment/azure/aca-deployment-visual-studio.md @@ -1,12 +1,12 @@ --- -title: Deploy .NET Aspire apps to Azure Container Apps using Visual Studio -description: Learn how to use Bicep, the Azure CLI, and Azure Developer CLI to deploy .NET Aspire apps to Azure using Visual Studio. +title: Deploy .NET Aspire projects to Azure Container Apps using Visual Studio +description: Learn how to use Bicep, the Azure CLI, and Azure Developer CLI to deploy .NET Aspire projects to Azure using Visual Studio. ms.date: 05/18/2024 --- -# Deploy a .NET Aspire app to Azure Container Apps using Visual Studio +# Deploy a .NET Aspire project to Azure Container Apps using Visual Studio -.NET Aspire apps are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. This article will walk you through creating a new .NET Aspire solution and deploying it to Microsoft Azure Container Apps using the Visual Studio. You'll learn how to complete the following tasks: +.NET Aspire projects are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. This article will walk you through creating a new .NET Aspire solution and deploying it to Microsoft Azure Container Apps using the Visual Studio. You'll learn how to complete the following tasks: > [!div class="checklist"] > @@ -18,9 +18,9 @@ ms.date: 05/18/2024 [!INCLUDE [aspire-prereqs](../../includes/aspire-prereqs.md)] -## Create a .NET Aspire app +## Create a .NET Aspire project -As a starting point, this article assumes that you've created a .NET Aspire app from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire app](../../get-started/build-your-first-aspire-app.md). +As a starting point, this article assumes that you've created a .NET Aspire project from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire project](../../get-started/build-your-first-aspire-app.md). ### Deploy the app diff --git a/docs/deployment/azure/aca-deployment.md b/docs/deployment/azure/aca-deployment.md index 608b89a6c..7dc5c8402 100644 --- a/docs/deployment/azure/aca-deployment.md +++ b/docs/deployment/azure/aca-deployment.md @@ -1,13 +1,13 @@ --- -title: Deploy .NET Aspire apps to Azure Container Apps -description: Learn how to use the Azure Developer CLI to deploy .NET Aspire apps to Azure. +title: Deploy .NET Aspire projects to Azure Container Apps +description: Learn how to use the Azure Developer CLI to deploy .NET Aspire projects to Azure. ms.date: 05/18/2024 ms.custom: devx-track-extended-azdevcli --- -# Deploy a .NET Aspire app to Azure Container Apps +# Deploy a .NET Aspire project to Azure Container Apps -.NET Aspire apps are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. This article will walk you through creating a new .NET Aspire solution and deploying it to Microsoft Azure Container Apps using the Azure Developer CLI (`azd`). You'll learn how to complete the following tasks: +.NET Aspire projects are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. This article will walk you through creating a new .NET Aspire solution and deploying it to Microsoft Azure Container Apps using the Azure Developer CLI (`azd`). You'll learn how to complete the following tasks: > [!div class="checklist"] > @@ -19,15 +19,15 @@ ms.custom: devx-track-extended-azdevcli [!INCLUDE [aspire-prereqs](../../includes/aspire-prereqs.md)] -As an alternative to this tutorial and for a more in-depth guide, see [Deploy a .NET Aspire app to Azure Container Apps using `azd` (in-depth guide)](aca-deployment-azd-in-depth.md). +As an alternative to this tutorial and for a more in-depth guide, see [Deploy a .NET Aspire project to Azure Container Apps using `azd` (in-depth guide)](aca-deployment-azd-in-depth.md). -## Deploy .NET Aspire apps with `azd` +## Deploy .NET Aspire projects with `azd` With .NET Aspire and Azure Container Apps (ACA), you have a great hosting scenario for building out your cloud-native apps with .NET. We built some great new features into the Azure Developer CLI (`azd`) specific for making .NET Aspire development and deployment to Azure a friction-free experience. You can still use the Azure CLI and/or Bicep options when you need a granular level of control over your deployments. But for new projects, you won't find an easier path to success for getting a new microservice topology deployed into the cloud. -## Create a .NET Aspire app +## Create a .NET Aspire project -As a starting point, this article assumes that you've created a .NET Aspire app from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire app](../../get-started/build-your-first-aspire-app.md). +As a starting point, this article assumes that you've created a .NET Aspire project from the **.NET Aspire Starter Application** template. For more information, see [Quickstart: Build your first .NET Aspire project](../../get-started/build-your-first-aspire-app.md). ## Install the Azure Developer CLI diff --git a/docs/deployment/azure/application-insights.md b/docs/deployment/azure/application-insights.md index 783b443a2..e39f5d565 100644 --- a/docs/deployment/azure/application-insights.md +++ b/docs/deployment/azure/application-insights.md @@ -7,13 +7,13 @@ ms.topic: how-to # Use Application Insights for .NET Aspire telemetry -Azure Application Insights, a feature of Azure Monitor, excels in Application Performance Management (APM) for live web applications. .NET Aspire apps are designed to use OpenTelemetry for application telemetry. OpenTelemetry supports an extension model to support sending data to different APMs. .NET Aspire uses OTLP by default for telemetry export, which is used by the dashboard during development. Azure Monitor doesn't (yet) support OTLP, so the applications need to be modified to use the Azure Monitor exporter, and configured with the connection string. +Azure Application Insights, a feature of Azure Monitor, excels in Application Performance Management (APM) for live web applications. .NET Aspire projects are designed to use OpenTelemetry for application telemetry. OpenTelemetry supports an extension model to support sending data to different APMs. .NET Aspire uses OTLP by default for telemetry export, which is used by the dashboard during development. Azure Monitor doesn't (yet) support OTLP, so the applications need to be modified to use the Azure Monitor exporter, and configured with the connection string. To use Application insights, you specify its configuration in the app host project *and* use the [Azure Monitor distro in the service defaults project](#use-the-azure-monitor-distro). ## Choosing how Application Insights is provisioned -.NET Aspire has the capability to provision cloud resources as part of cloud deployment, including Application Insights. In your .NET Aspire app, you can decide if you want .NET Aspire to provision an Application Insights resource when deploying to Azure. You can also select to use an existing Application Insights resource by providing its connection string. The connection information is managed by the resource configuration in the app host project. +.NET Aspire has the capability to provision cloud resources as part of cloud deployment, including Application Insights. In your .NET Aspire project, you can decide if you want .NET Aspire to provision an Application Insights resource when deploying to Azure. You can also select to use an existing Application Insights resource by providing its connection string. The connection information is managed by the resource configuration in the app host project. ### Provisioning Application insights during Azure deployment @@ -42,7 +42,7 @@ builder.AddProject("webfrontend") builder.Build().Run(); ``` -Follow the steps in [Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide)](./aca-deployment-azd-in-depth.md) to deploy the application to Azure Container Apps. `azd` will create an Application Insights resource as part of the same resource group, and configure the connection string for each container. +Follow the steps in [Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide)](./aca-deployment-azd-in-depth.md) to deploy the application to Azure Container Apps. `azd` will create an Application Insights resource as part of the same resource group, and configure the connection string for each container. ### Manual provisioning of Application Insights resource @@ -71,7 +71,7 @@ builder.Build().Run(); #### Resource usage during developemnt -When running the .NET Aspire app locally, the preceding code reads the connection string from configuration. As this is a secret, you should store the value in [app secrets](/aspnet/core/security/app-secrets). Right click on the app host project and choose **Manage Secrets** from the context menu to open the secrets file for the app host project. In the file add the key and your specific connection string, the example below is for illustration purposes. +When running the .NET Aspire project locally, the preceding code reads the connection string from configuration. As this is a secret, you should store the value in [app secrets](/aspnet/core/security/app-secrets). Right click on the app host project and choose **Manage Secrets** from the context menu to open the secrets file for the app host project. In the file add the key and your specific connection string, the example below is for illustration purposes. ```json { diff --git a/docs/deployment/azure/custom-bicep-templates.md b/docs/deployment/azure/custom-bicep-templates.md index 18d7b5003..6f0e8b9cf 100644 --- a/docs/deployment/azure/custom-bicep-templates.md +++ b/docs/deployment/azure/custom-bicep-templates.md @@ -13,7 +13,7 @@ While .NET Aspire provides a set of pre-built Bicep templates so that you don't > [!IMPORTANT] > This article is not intended to teach Bicep, but rather to provide guidance on how to create customize Bicep templates for use with .NET Aspire. -As part of the Azure deployment story for .NET Aspire, the Azure Developer CLI (`azd`) provides an understanding of your .NET Aspire application and the ability to deploy it to Azure. The `azd` CLI uses the Bicep templates to deploy the application to Azure. +As part of the Azure deployment story for .NET Aspire, the Azure Developer CLI (`azd`) provides an understanding of your .NET Aspire project and the ability to deploy it to Azure. The `azd` CLI uses the Bicep templates to deploy the application to Azure. ## Install App Host package @@ -168,6 +168,6 @@ When this resource is deployed, the underlying deployment mechanism with automat For continued learning, see the following resources as they relate to .NET Aspire and Azure deployment: -- [Deploy a .NET Aspire app to Azure Container Apps](aca-deployment.md) -- [Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide)](aca-deployment-azd-in-depth.md) +- [Deploy a .NET Aspire project to Azure Container Apps](aca-deployment.md) +- [Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide)](aca-deployment-azd-in-depth.md) - [.NET Aspire manifest format for deployment tool builders](../manifest-format.md) diff --git a/docs/deployment/azure/includes/aca-bicep-cli-shared-steps.md b/docs/deployment/azure/includes/aca-bicep-cli-shared-steps.md index 53c02b351..a6b82dd66 100644 --- a/docs/deployment/azure/includes/aca-bicep-cli-shared-steps.md +++ b/docs/deployment/azure/includes/aca-bicep-cli-shared-steps.md @@ -93,7 +93,7 @@ ENVIRONMENT="${SOLUTION,,}cae" # Azure Container Apps Environment name, ## Provision the Azure resources -Azure Container Apps (ACA) is an ideal hosting platform for .NET Aspire apps. You can use Bicep or the Azure CLI to create resources in Azure to host the .NET Aspire app code along with supporting services: +Azure Container Apps (ACA) is an ideal hosting platform for .NET Aspire projects. You can use Bicep or the Azure CLI to create resources in Azure to host the .NET Aspire project code along with supporting services: - An Azure Container Apps Environment to host your code and tertiary containers - A pair of Azure Container Apps, hosting your code diff --git a/docs/deployment/azure/includes/test-deployed-app.md b/docs/deployment/azure/includes/test-deployed-app.md index c496fe1e7..9663795e9 100644 --- a/docs/deployment/azure/includes/test-deployed-app.md +++ b/docs/deployment/azure/includes/test-deployed-app.md @@ -2,14 +2,14 @@ Now that the app has been provisioned and deployed, you can browse to the Azure portal. In the resource group where you deployed the app, you'll see the three container apps and other resources. -:::image type="content" loc-scope="azure" source="../media/azd-azure-portal-deployed-resources.png" lightbox="../media/azd-azure-portal-deployed-resources.png" alt-text="A screenshot of the .NET Aspire app's resource group in the Azure portal."::: +:::image type="content" loc-scope="azure" source="../media/azd-azure-portal-deployed-resources.png" lightbox="../media/azd-azure-portal-deployed-resources.png" alt-text="A screenshot of the .NET Aspire project's resource group in the Azure portal."::: Click on the `web` Container App to open it up in the portal. -:::image type="content" loc-scope="azure" source="../../../media/portal-screens-web-container-app.png" lightbox="../../../media/portal-screens-web-container-app.png" alt-text="A screenshot of the .NET Aspire app's front end in the Azure portal."::: +:::image type="content" loc-scope="azure" source="../../../media/portal-screens-web-container-app.png" lightbox="../../../media/portal-screens-web-container-app.png" alt-text="A screenshot of the .NET Aspire project's front end in the Azure portal."::: Click the **Application URL** link to open the front end in the browser. -:::image type="content" source="../../../media/front-end-open.png" lightbox="../../../media/front-end-open.png" alt-text="A screenshot of the .NET Aspire app's front end in the browser."::: +:::image type="content" source="../../../media/front-end-open.png" lightbox="../../../media/front-end-open.png" alt-text="A screenshot of the .NET Aspire project's front end in the browser."::: When you click the "Weather" node in the navigation bar, the front end `web` container app makes a call to the `apiservice` container app to get data. The front end's output will be cached using the `redis` container app and the [.NET Aspire Redis Output Caching component](../../../caching/stackexchange-redis-output-caching-component.md). As you refresh the front end a few times, you'll notice that the weather data is cached. It will update after a few seconds. diff --git a/docs/deployment/manifest-format.md b/docs/deployment/manifest-format.md index 3e67149f5..109ea244d 100644 --- a/docs/deployment/manifest-format.md +++ b/docs/deployment/manifest-format.md @@ -7,14 +7,14 @@ ms.topic: reference # .NET Aspire manifest format for deployment tool builders -In this article, you learn about the .NET Aspire manifest format. This article serves as a reference guide for deployment tool builders, aiding in the creation of tooling to deploy .NET Aspire applications on specific hosting platforms, whether on-premises or in the cloud. +In this article, you learn about the .NET Aspire manifest format. This article serves as a reference guide for deployment tool builders, aiding in the creation of tooling to deploy .NET Aspire projects on specific hosting platforms, whether on-premises or in the cloud. .NET Aspire [simplifies the local development experience](../fundamentals/networking-overview.md) by helping to manage interdependencies between application components. To help simplify the deployment of applications, .NET Aspire projects can generate a manifest of all the resources defined as a JSON formatted file. ## Generate a manifest -A valid .NET Aspire application is required to generate a manifest. To get started, create -a .NET Aspire application using the `aspire-starter` .NET template: +A valid .NET Aspire project is required to generate a manifest. To get started, create +a .NET Aspire project using the `aspire-starter` .NET template: ```dotnetcli dotnet new aspire-starter --use-redis-cache ` @@ -934,7 +934,7 @@ Example manifest: ### Resource types supported in the Azure Developer CLI -The [Azure Developer CLI](/azure/developer/azure-developer-cli/) (azd) is a tool that can be used to deploy .NET Aspire applications to Azure Container Apps. With the `azure.bicep.v0` resource type, cloud-agnostic resource container types can be mapped to Azure-specific resources. The following table lists the resource types that are supported in the Azure Developer CLI: +The [Azure Developer CLI](/azure/developer/azure-developer-cli/) (azd) is a tool that can be used to deploy .NET Aspire projects to Azure Container Apps. With the `azure.bicep.v0` resource type, cloud-agnostic resource container types can be mapped to Azure-specific resources. The following table lists the resource types that are supported in the Azure Developer CLI: | Name | Cloud-agnostic API | Configure as Azure resource | | ---- | ---------------------------- | ---------------------------------- | @@ -942,7 +942,7 @@ The [Azure Developer CLI](/azure/developer/azure-developer-cli/) (azd) is a tool | Postgres | | `PublishAsAzurePostgresFlexibleServer` | | SQL Server | | `PublishAsAzureSqlDatabase` | -When resources as configured as Azure resources, the `azure.bicep.v0` resource type is generated in the manifest. For more information, see [Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide)](azure/aca-deployment-azd-in-depth.md). +When resources as configured as Azure resources, the `azure.bicep.v0` resource type is generated in the manifest. For more information, see [Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide)](azure/aca-deployment-azd-in-depth.md). ## See also diff --git a/docs/deployment/overview.md b/docs/deployment/overview.md index c42ec967a..85d62d2d3 100644 --- a/docs/deployment/overview.md +++ b/docs/deployment/overview.md @@ -7,11 +7,11 @@ ms.date: 05/21/2024 # .NET Aspire deployments -.NET Aspire applications are built with cloud-agnostic principles, allowing deployment flexibility across various platforms supporting .NET and containers. Users can adapt the provided guidelines for deployment on other cloud environments or local hosting. The manual deployment process, while feasible, involves exhaustive steps prone to errors. Users prefer leveraging CI/CD pipelines and cloud-specific tooling for a more streamlined deployment experience tailored to their chosen infrastructure. +.NET Aspire projects are built with cloud-agnostic principles, allowing deployment flexibility across various platforms supporting .NET and containers. Users can adapt the provided guidelines for deployment on other cloud environments or local hosting. The manual deployment process, while feasible, involves exhaustive steps prone to errors. Users prefer leveraging CI/CD pipelines and cloud-specific tooling for a more streamlined deployment experience tailored to their chosen infrastructure. ## Deployment manifest -To enable deployment tools from Microsoft and other cloud providers to understand the structure of .NET Aspire applications, specialized targets of the [AppHost project](../fundamentals/app-host-overview.md) can be executed to generate a manifest file describing the projects/services used by the app and the properties necessary for deployment, such as environment variables. +To enable deployment tools from Microsoft and other cloud providers to understand the structure of .NET Aspire projects, specialized targets of the [AppHost project](../fundamentals/app-host-overview.md) can be executed to generate a manifest file describing the projects/services used by the app and the properties necessary for deployment, such as environment variables. For more information on the schema of the manifest and how to run app host project targets, see [.NET Aspire manifest format for deployment tool builders](manifest-format.md). @@ -21,15 +21,15 @@ For more information on the schema of the manifest and how to run app host proje ### Azure Container Apps -.NET Aspire apps are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. The [Azure Container Apps](azure/aca-deployment.md) topic describes how to deploy Aspire apps to ACA manually, using bicep, or using the Azure Developer CLI (azd). +.NET Aspire projects are designed to run in containerized environments. Azure Container Apps is a fully managed environment that enables you to run microservices and containerized applications on a serverless platform. The [Azure Container Apps](azure/aca-deployment.md) topic describes how to deploy Aspire apps to ACA manually, using bicep, or using the Azure Developer CLI (azd). ### Use Application Insights for .NET Aspire telemetry -.NET Aspire apps are designed to emit telemetry using OpenTelemetry which uses a provider model. .NET Aspire Apps can direct their telemetry to Azure Monitor / Application Insights using the Azure Monitor telemetry distro. For more information, see [Use Application Insights for .NET Aspire telemetry](azure/application-insights.md) for step-by-step instructions. +.NET Aspire projects are designed to emit telemetry using OpenTelemetry which uses a provider model. .NET Aspire projects can direct their telemetry to Azure Monitor / Application Insights using the Azure Monitor telemetry distro. For more information, see [Use Application Insights for .NET Aspire telemetry](azure/application-insights.md) for step-by-step instructions. ## Deploy to Kubernetes -Kubernetes is a popular container orchestration platform that can run .NET Aspire applications. To deploy .NET Aspire apps to Kubernetes clusters, you need to map the .NET Aspire JSON manifest to a Kubernetes YAML manifest file. There are two ways to do this: by using the Aspir8 project, or by manually creating Kubernetes manifests. +Kubernetes is a popular container orchestration platform that can run .NET Aspire projects. To deploy .NET Aspire projects to Kubernetes clusters, you need to map the .NET Aspire JSON manifest to a Kubernetes YAML manifest file. There are two ways to do this: by using the Aspir8 project, or by manually creating Kubernetes manifests. ### The Aspir8 project diff --git a/docs/extensibility/custom-resources.md b/docs/extensibility/custom-resources.md index f392e5595..42af28c4a 100644 --- a/docs/extensibility/custom-resources.md +++ b/docs/extensibility/custom-resources.md @@ -45,11 +45,11 @@ When custom resource requires optional configuration, developers may wish to imp To help understand how to develop custom resources, this article shows an example of how to build a custom resource for [MailDev](https://maildev.github.io/maildev/). MailDev is an open-source tool which provides a local mail server specifically designed to allow developers to test e-mail sending behaviors within their app. For more information, see [the MailDev GitHub repository](https://github.com/maildev/maildev). -In this example you create a new .NET Aspire app as a test environment for the MailDev resource that you create. While you can create custom resources in existing .NET Aspire apps it's a good idea to consider whether the custom resource might be used across multiple .NET Aspire-based solutions and should be developed as a reusable component. +In this example you create a new .NET Aspire project as a test environment for the MailDev resource that you create. While you can create custom resources in existing .NET Aspire projects it's a good idea to consider whether the custom resource might be used across multiple .NET Aspire-based solutions and should be developed as a reusable component. ## Setup the starter project -Create a new .NET Aspire app that will be used to test out the new resource that we are developing. +Create a new .NET Aspire project that will be used to test out the new resource that we are developing. ```dotnetcli dotnet new aspire -o MailDevResource @@ -346,7 +346,7 @@ In the preceding code, the `MailDevResource` had two properties: - `SmtpEndpoint`: type. - `ConnectionStringExpression`: type. -These types are among several which are used throughout .NET Aspire to represent configuration data, which isn't finalized until the .NET Aspire application is either run or published to the cloud via a tool such as [Azure Developer CLI (`azd`)](/azure/developer/azure-developer-cli/overview). +These types are among several which are used throughout .NET Aspire to represent configuration data, which isn't finalized until the .NET Aspire project is either run or published to the cloud via a tool such as [Azure Developer CLI (`azd`)](/azure/developer/azure-developer-cli/overview). The fundamental problem that these types help to solve, is deferring resolution of concrete configuration information until _all_ the information is available. @@ -372,7 +372,7 @@ Here's how the flow of execution works: 1. A resource which implements is added to the model (for example, `AddMailDev(...)`). 1. The `IResourceBuilder` is passed to the which has a special overload for handling implementors. -1. The `WithReference` wraps the resource in a instance and the object is captured in a which is evaluated after the .NET Aspire application is built and starts running. +1. The `WithReference` wraps the resource in a instance and the object is captured in a which is evaluated after the .NET Aspire project is built and starts running. 1. As the process that references the connection string starts .NET Aspire starts evaluating the expression. It first gets the and calls . 1. The `GetValueAsync` method gets the value of the property to get the instance. 1. The method then calls to process the previously captured interpolated string. diff --git a/docs/frameworks/dapr.md b/docs/frameworks/dapr.md index 0caaee056..95111d64c 100644 --- a/docs/frameworks/dapr.md +++ b/docs/frameworks/dapr.md @@ -132,9 +132,9 @@ At first sight Dapr and .NET Aspire may look like they have overlapping function Dapr provides many [built-in components](https://docs.dapr.io/concepts/components-concept), and when you use Dapr with .NET Aspire you can easily explore and configure these components. Don't confuse these components with .NET Aspire components. For example, consider the following: -- [Dapr—State stores](https://docs.dapr.io/concepts/components-concept/#state-stores): Call to add a configured state store to your .NET Aspire app. -- [Dapr—Pub Sub](https://docs.dapr.io/concepts/components-concept/#pubsub-brokers): Call to add a configured pub sub to your .NET Aspire app. -- Dapr—Components: Call to add a configured component to your .NET Aspire app. +- [Dapr—State stores](https://docs.dapr.io/concepts/components-concept/#state-stores): Call to add a configured state store to your .NET Aspire project. +- [Dapr—Pub Sub](https://docs.dapr.io/concepts/components-concept/#pubsub-brokers): Call to add a configured pub sub to your .NET Aspire project. +- Dapr—Components: Call to add a configured component to your .NET Aspire project. ## Next steps diff --git a/docs/frameworks/orleans.md b/docs/frameworks/orleans.md index fffe3d3aa..57a7b5133 100644 --- a/docs/frameworks/orleans.md +++ b/docs/frameworks/orleans.md @@ -79,7 +79,7 @@ You do similarly in the _OrleansClient_ project, adding the .NET Aspire resource ## Enabling OpenTelemetry -By convention, .NET Aspire application include a project for defining default configuration and behavior for your service. This project is called the _service default_ project and templates create it with a name ending in _ServiceDefaults_. +By convention, .NET Aspire project include a project for defining default configuration and behavior for your service. This project is called the _service default_ project and templates create it with a name ending in _ServiceDefaults_. To configure Orleans for OpenTelemetry in .NET Aspire, you will need to apply configuration to your service defaults project following the [Orleans observability](/dotnet/orleans/host/monitoring/) guide. In short, you will need to modify the `ConfigureOpenTelemetry` method to add the Orleans _meters_ and _tracing_ instruments. The following code snippet shows the _Extensions.cs_ file from a service defaults project which has been modified to include metrics and traces from Orleans. diff --git a/docs/fundamentals/app-host-overview.md b/docs/fundamentals/app-host-overview.md index c5adb3199..b095d9e35 100644 --- a/docs/fundamentals/app-host-overview.md +++ b/docs/fundamentals/app-host-overview.md @@ -21,11 +21,11 @@ Before continuing, consider some common terminology used in .NET Aspire: ## Define the app model -.NET Aspire empowers you to seamlessly build, provision, deploy, configure, test, run, and observe your cloud application. This is achieved through the utilization of an _app model_ that outlines the resources in your app and their relationships. These resources encompass projects, executables, containers, as well as external services and cloud resources that your app depends on. Within every .NET Aspire app, there is a designated [App host project](#app-host-project), where the app model is precisely defined using methods available on the . This builder is obtained by invoking . +.NET Aspire empowers you to seamlessly build, provision, deploy, configure, test, run, and observe your cloud application. This is achieved through the utilization of an _app model_ that outlines the resources in your app and their relationships. These resources encompass projects, executables, containers, as well as external services and cloud resources that your app depends on. Within every .NET Aspire project, there is a designated [App host project](#app-host-project), where the app model is precisely defined using methods available on the . This builder is obtained by invoking . ## App host project -The app host project handles running all of the projects that are part of the .NET Aspire application. In other words, it's responsible for orchestrating all apps within the app model. The following code describes an application with two projects and a Redis cache: +The app host project handles running all of the projects that are part of the .NET Aspire project. In other words, it's responsible for orchestrating all apps within the app model. The following code describes an application with two projects and a Redis cache: ```csharp var builder = DistributedApplication.CreateBuilder(args); @@ -49,7 +49,7 @@ Each resource must be uniquely named. This diagram shows each resource and the r ## Built-in resource types -.NET Aspire apps are made up of a set of resources. There are three base types of compute resources: +.NET Aspire projects are made up of a set of resources. There are three base types of compute resources: | Method | Resource type | Description | |--|--|--| diff --git a/docs/fundamentals/components-overview.md b/docs/fundamentals/components-overview.md index 28e22b433..14b96c65a 100644 --- a/docs/fundamentals/components-overview.md +++ b/docs/fundamentals/components-overview.md @@ -9,7 +9,7 @@ ms.topic: conceptual .NET Aspire components are a curated suite of NuGet packages specifically selected to facilitate the integration of cloud-native applications with prominent services and platforms, including but not limited to Redis and PostgreSQL. Each component furnishes essential cloud-native functionalities through either automatic provisioning or standardized configuration patterns. .NET Aspire components can be used without an app host (orchestrator) project, but they're designed to work best with the [.NET Aspire app host](app-host-overview.md). -.NET Aspire components should not be confused with .NET Aspire hosting packages, as they serve different purposes. Hosting packages are used to model and configure various resources in a .NET Aspire app, while components are used to map configuration to various client libraries. +.NET Aspire components should not be confused with .NET Aspire hosting packages, as they serve different purposes. Hosting packages are used to model and configure various resources in a .NET Aspire project, while components are used to map configuration to various client libraries. > [!TIP] > Always strive to use the latest version of .NET Aspire components to take advantage of the latest features, improvements, and security updates. @@ -53,7 +53,7 @@ For more information on working with .NET Aspire components in Visual Studio, se ## Explore a sample component workflow -.NET Aspire components streamline the process of consuming popular services and platforms. For example, consider the **.NET Aspire Application** template. With this template, you get the [AppHost](app-host-overview.md) and [ServiceDefaults](service-defaults.md) projects. Imagine that you have a need for a worker service to perform some database processing. You could use the [.NET Aspire PostgreSQL component](../database/postgresql-component.md) to connect to and utilize a PostgreSQL database. The database could be hosted on-prem or in a cloud service such as Azure, AWS, or GCP. The following steps demonstrate how to integrate this component into your app: +.NET Aspire components streamline the process of consuming popular services and platforms. For example, consider the **.NET Aspire project** template. With this template, you get the [AppHost](app-host-overview.md) and [ServiceDefaults](service-defaults.md) projects. Imagine that you have a need for a worker service to perform some database processing. You could use the [.NET Aspire PostgreSQL component](../database/postgresql-component.md) to connect to and utilize a PostgreSQL database. The database could be hosted on-prem or in a cloud service such as Azure, AWS, or GCP. The following steps demonstrate how to integrate this component into your app: 1. In the component consuming (worker service) project, install the [Aspire.Npgsql](https://www.nuget.org/packages/Aspire.Npgsql) NuGet package. @@ -167,9 +167,9 @@ For more information, see [Dependency injection in .NET: Keyed services](/dotnet Cloud-native applications surface many unique requirements and concerns. The core features of .NET Aspire orchestration and components are designed to handle many cloud-native concerns for you with minimal configurations. Some of the key features include: -- [Orchestration](app-host-overview.md): A lightweight, extensible, and cross-platform app host for .NET Aspire apps. The app host provides a consistent configuration and dependency injection experience for .NET Aspire components. +- [Orchestration](app-host-overview.md): A lightweight, extensible, and cross-platform app host for .NET Aspire projects. The app host provides a consistent configuration and dependency injection experience for .NET Aspire components. - [Service discovery](../service-discovery/overview.md): A technique for locating services within a distributed application. Service discovery is a key component of microservice architectures. -- [Service defaults](service-defaults.md): A set of default configurations intended for sharing amongst resources within .NET Aspire apps. These defaults are designed to work well in most scenarios and can be customized as needed. +- [Service defaults](service-defaults.md): A set of default configurations intended for sharing amongst resources within .NET Aspire projects. These defaults are designed to work well in most scenarios and can be customized as needed. Some .NET Aspire components also include more capabilities for specific services or platforms, which can be found in the component specific reference docs. diff --git a/docs/fundamentals/dashboard/explore.md b/docs/fundamentals/dashboard/explore.md index 2d84044ef..bcd99aa76 100644 --- a/docs/fundamentals/dashboard/explore.md +++ b/docs/fundamentals/dashboard/explore.md @@ -7,11 +7,11 @@ ms.topic: reference # Explore the .NET Aspire dashboard -In the upcoming sections, you'll discover how to create a .NET Aspire app and embark on the following tasks: +In the upcoming sections, you'll discover how to create a .NET Aspire project and embark on the following tasks: > [!div class="checklist"] > -> - Investigate the dashboard's capabilities by using the app generated from the project template as explained in the [Quickstart: Build your first .NET Aspire app.](../../get-started/build-your-first-aspire-app.md) +> - Investigate the dashboard's capabilities by using the app generated from the project template as explained in the [Quickstart: Build your first .NET Aspire project.](../../get-started/build-your-first-aspire-app.md) > > - Delve into the features of the .NET Aspire dashboard app. @@ -43,10 +43,10 @@ The dashboard persists the token as a browser persistent cookie, which remains v ## Resources page -The **Resources** page is the default home page of the .NET Aspire dashboard. This page lists all of the .NET projects, containers, and executables included in your .NET Aspire app. For example, the starter application includes two projects: +The **Resources** page is the default home page of the .NET Aspire dashboard. This page lists all of the .NET projects, containers, and executables included in your .NET Aspire project. For example, the starter application includes two projects: -- **apiservice**: A back-end API for the .NET Aspire app built using Minimal APIs. -- **webfrontend**: The front-end UI for the .NET Aspire app built using Blazor. +- **apiservice**: A back-end API for the .NET Aspire project built using Minimal APIs. +- **webfrontend**: The front-end UI for the .NET Aspire project built using Blazor. The dashboard also provides essential details about each resource: @@ -68,7 +68,7 @@ You can obtain full details about each resource by selecting the **View** link i :::image type="content" source="media/explore/resource-details.png" lightbox="media/explore/resource-details.png" alt-text="A screenshot of the .NET Aspire dashboard Resources page with the details of a selected resource displayed.."::: -The search bar in the upper right of the dashboard also provides the option to filter the list, which is useful for .NET Aspire apps with many resources. To select the types of resources that are displayed, drop down the arrow to the left of the filter textbox: +The search bar in the upper right of the dashboard also provides the option to filter the list, which is useful for .NET Aspire projects with many resources. To select the types of resources that are displayed, drop down the arrow to the left of the filter textbox: :::image type="content" source="media/explore/select-resource-type.png" alt-text="A screenshot of the resource type selector list in the .NET Aspire dashboard Resources page."::: @@ -76,7 +76,7 @@ In this example, only containers are displayed in the list. For example, if you :::image type="content" source="media/explore/resources-filtered-containers.png" lightbox="media/explore/resources-filtered-containers.png" alt-text="A screenshot of the .NET Aspire dashboard Resources page filtered to show only containers."::: -Executables are stand-alone processes. You can configure a .NET Aspire app to run a stand-alone executable during startup, though the default starter templates do not include any executables by default. +Executables are stand-alone processes. You can configure a .NET Aspire project to run a stand-alone executable during startup, though the default starter templates do not include any executables by default. The following screenshot shows an example of a project that has errors: @@ -121,7 +121,7 @@ If you select a container or executable, formatting is different from a project ### Structured logs page -.NET Aspire automatically configures your projects with logging using OpenTelemetry. Navigate to the **Structured logs** page to view the semantic logs for your .NET Aspire app. [Semantic, or structured logging](https://github.com/NLog/NLog/wiki/How-to-use-structured-logging) makes it easier to store and query log-events, as the log-event message-template and message-parameters are preserved, instead of just transforming them into a formatted message. You'll notice a clean structure for the different logs displayed on the page using columns: +.NET Aspire automatically configures your projects with logging using OpenTelemetry. Navigate to the **Structured logs** page to view the semantic logs for your .NET Aspire project. [Semantic, or structured logging](https://github.com/NLog/NLog/wiki/How-to-use-structured-logging) makes it easier to store and query log-events, as the log-event message-template and message-parameters are preserved, instead of just transforming them into a formatted message. You'll notice a clean structure for the different logs displayed on the page using columns: - **Resource**: The resource the log originated from. - **Level**: The log level of the entry, such as information, warning, or error. @@ -169,7 +169,7 @@ The trace details page contains various details pertinent to the request, includ - **Depth**: The number of layers involved in the request. - **Total Spans**: The total number of spans involved in the request. -Each span is represented as a row in the table, and contains a **Name**. Spans also display the error icon if an error occurred within that particular span of the trace. Spans that have a type of client/consumer, but don't have a span on the server, show an arrow icon and then the destination address. This represents a client call to a system outside of the .NET Aspire application. For example, an HTTP request an external web API, or a database call. +Each span is represented as a row in the table, and contains a **Name**. Spans also display the error icon if an error occurred within that particular span of the trace. Spans that have a type of client/consumer, but don't have a span on the server, show an arrow icon and then the destination address. This represents a client call to a system outside of the .NET Aspire project. For example, an HTTP request an external web API, or a database call. Within the trace details page, there's a **View Logs** button that takes you to the structured logs page with a filter applied to show only the logs relevant to the request. Consider an example screenshot depicting the structured logs page with a filter applied to show only the logs relevant to the trace: diff --git a/docs/fundamentals/dashboard/overview.md b/docs/fundamentals/dashboard/overview.md index 0a073dfa7..7d80ef2d7 100644 --- a/docs/fundamentals/dashboard/overview.md +++ b/docs/fundamentals/dashboard/overview.md @@ -11,7 +11,7 @@ ms.topic: reference ## Using the dashboard with .NET Aspire projects -The dashboard is integrated into the .NET Aspire **AppHost**. During development the dashboard is automatically launched when you start the project. It's configured to display the .NET Aspire app's resources and telemetry. +The dashboard is integrated into the .NET Aspire **AppHost**. During development the dashboard is automatically launched when you start the project. It's configured to display the .NET Aspire project's resources and telemetry. :::image type="content" source="media/explore/projects.png" lightbox="media/explore/projects.png" alt-text="A screenshot of the .NET Aspire dashboard Resources page."::: diff --git a/docs/fundamentals/launch-profiles.md b/docs/fundamentals/launch-profiles.md index ffc9c7014..ffc895ae6 100644 --- a/docs/fundamentals/launch-profiles.md +++ b/docs/fundamentals/launch-profiles.md @@ -56,7 +56,7 @@ When a .NET application is launched with a launch profile a special environment ## Launch profiles for .NET Aspire app host -In .NET Aspire, the AppHost is just a .NET application. As a result it has a `launchSettings.json` file just like any other application. Here is an example of the `launchSettings.json` file generated when creating a new .NET Aspire application from the starter template (`dotnet new aspire-starter`). +In .NET Aspire, the AppHost is just a .NET application. As a result it has a `launchSettings.json` file just like any other application. Here is an example of the `launchSettings.json` file generated when creating a new .NET Aspire project from the starter template (`dotnet new aspire-starter`). ```json { @@ -90,7 +90,7 @@ In .NET Aspire, the AppHost is just a .NET application. As a result it has a `la } ``` -The .NET Aspire templates have a very similar set of _launch profiles_ to a regular ASP.NET Core application. When the .NET Aspire application launches it hosts a web-server which is used by the .NET Aspire Dashboard to fetch information about resources which are being orchestrated by .NET Aspire. There are some additional environment variables which are defined which are covered in [.NET Aspire dashboard configuration](./dashboard/configuration.md). +The .NET Aspire templates have a very similar set of _launch profiles_ to a regular ASP.NET Core application. When the .NET Aspire project launches it hosts a web-server which is used by the .NET Aspire Dashboard to fetch information about resources which are being orchestrated by .NET Aspire. There are some additional environment variables which are defined which are covered in [.NET Aspire dashboard configuration](./dashboard/configuration.md). ## Relationship between app host launch profiles and service projects diff --git a/docs/fundamentals/persist-data-volumes.md b/docs/fundamentals/persist-data-volumes.md index 6ed124aae..7c67c10a4 100644 --- a/docs/fundamentals/persist-data-volumes.md +++ b/docs/fundamentals/persist-data-volumes.md @@ -5,19 +5,19 @@ ms.date: 04/26/2024 ms.topic: how-to --- -# Persist .NET Aspire app data using volumes +# Persist .NET Aspire project data using volumes -In this article, you learn how to configure .NET Aspire apps to persist data across app launches using volumes. A continuous set of data during local development is useful in many scenarios. Various .NET Aspire resource container types are able to leverage volume storage, such as PostgreSQL, Redis and Azure Storage. +In this article, you learn how to configure .NET Aspire projects to persist data across app launches using volumes. A continuous set of data during local development is useful in many scenarios. Various .NET Aspire resource container types are able to leverage volume storage, such as PostgreSQL, Redis and Azure Storage. ## When to use volumes -By default, every time you start and stop a .NET Aspire app, the app also creates and destroys the app resource containers. This setup creates problems when you want to persist data in a database or storage services between app launches for testing or debugging. For example, you may want to handle the following scenarios: +By default, every time you start and stop a .NET Aspire project, the app also creates and destroys the app resource containers. This setup creates problems when you want to persist data in a database or storage services between app launches for testing or debugging. For example, you may want to handle the following scenarios: - Work with a continuous set of data in a database during an extended development session. - Test or debug a changing set of files in an Azure Blob Storage emulator. - Maintain cached data or messages in a Redis instance across app launches. -These goals can all be accomplished using volumes. With volumes, you decide which services retain data between launches of your .NET Aspire app. +These goals can all be accomplished using volumes. With volumes, you decide which services retain data between launches of your .NET Aspire project. ## Understand volumes diff --git a/docs/fundamentals/setup-tooling.md b/docs/fundamentals/setup-tooling.md index 166532abe..6395bd758 100644 --- a/docs/fundamentals/setup-tooling.md +++ b/docs/fundamentals/setup-tooling.md @@ -94,7 +94,7 @@ dotnet workload list ## Container runtime -.NET Aspire apps are designed to run in containers. You can use either Docker Desktop or Podman as your container runtime. [Docker Desktop](https://www.docker.com/products/docker-desktop/) is the most common container runtime. [Podman](https://podman.io/docs/installation) is an open-source daemonless alternative to Docker, that can build and run Open Container Initiative (OCI) containers. If your host environment has both Docker and Podman installed, .NET Aspire defaults to using Docker. You can instruct .NET Aspire to use Podman instead, by setting the `DOTNET_ASPIRE_CONTAINER_RUNTIME` environment variable to `podman`: +.NET Aspire projects are designed to run in containers. You can use either Docker Desktop or Podman as your container runtime. [Docker Desktop](https://www.docker.com/products/docker-desktop/) is the most common container runtime. [Podman](https://podman.io/docs/installation) is an open-source daemonless alternative to Docker, that can build and run Open Container Initiative (OCI) containers. If your host environment has both Docker and Podman installed, .NET Aspire defaults to using Docker. You can instruct .NET Aspire to use Podman instead, by setting the `DOTNET_ASPIRE_CONTAINER_RUNTIME` environment variable to `podman`: ## [Linux](#tab/linux) @@ -120,7 +120,7 @@ The .NET Aspire workload makes available .NET Aspire project templates. These pr There are currently four project templates available: -- **.NET Aspire Application**: A minimal .NET Aspire app that includes the following: +- **.NET Aspire project**: A minimal .NET Aspire project that includes the following: - **AspireSample.AppHost**: An orchestrator project designed to connect and configure the different projects and services of your app. @@ -267,14 +267,14 @@ When you're using Visual Studio, and you select the **.NET Aspire Start Applicat :::image type="content" source="media/setup-tooling/create-test-projects-template.png" lightbox="media/setup-tooling/create-test-projects-template.png" alt-text="A screenshot of Visual Studio displaying the option to create a test project."::: -For more information, see [Testing .NET Aspire apps](testing.md). +For more information, see [Testing .NET Aspire projects](testing.md). :::zone-end :::zone pivot="vscode" ## Visual Studio Code tooling -You can use Visual Studio Code, in conjunction with the [C# Dev Kit extension](https://marketplace.visualstudio.com/items?itemName=ms-dotnettools.csdevkit), to create and develop .NET Aspire apps. To create a new .NET Aspire app in Visual Studio Code, select the **Create .NET Project** button in the **Explorer** view, then select one of the .NET Aspire templates: +You can use Visual Studio Code, in conjunction with the [C# Dev Kit extension](https://marketplace.visualstudio.com/items?itemName=ms-dotnettools.csdevkit), to create and develop .NET Aspire projects. To create a new .NET Aspire project in Visual Studio Code, select the **Create .NET Project** button in the **Explorer** view, then select one of the .NET Aspire templates: :::image type="content" source="media/setup-tooling/vscode-create-project.png" lightbox="media/setup-tooling/vscode-create-project.png" alt-text="A screenshot showing how to create a new .NET Aspire project in Visual Studio Code."::: @@ -287,4 +287,4 @@ Once you've created a new .NET Aspire project, you run and debug the app, steppi ## See also - [Unable to install .NET Aspire workload](../troubleshooting/unable-to-install-workload.md) -- [Use Dev Proxy with .NET Aspire app](/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-dotnet-aspire) +- [Use Dev Proxy with .NET Aspire project](/microsoft-cloud/dev/dev-proxy/how-to/use-dev-proxy-with-dotnet-aspire) diff --git a/docs/fundamentals/telemetry.md b/docs/fundamentals/telemetry.md index 508c4bba2..5fc7a6a4d 100644 --- a/docs/fundamentals/telemetry.md +++ b/docs/fundamentals/telemetry.md @@ -18,7 +18,7 @@ Together, these types of telemetry allow you to gain insights into your applicat ## .NET Aspire OpenTelemetry integration -The [.NET OpenTelemetry SDK](https://github.com/open-telemetry/opentelemetry-dotnet) includes features for gathering data from several .NET APIs, including , , , and . These APIs correspond to telemetry features like logging, tracing, and metrics. .NET Aspire apps define OpenTelemetry SDK configurations in the _ServiceDefaults_ project. For more information, see [.NET Aspire service defaults](service-defaults.md). +The [.NET OpenTelemetry SDK](https://github.com/open-telemetry/opentelemetry-dotnet) includes features for gathering data from several .NET APIs, including , , , and . These APIs correspond to telemetry features like logging, tracing, and metrics. .NET Aspire projects define OpenTelemetry SDK configurations in the _ServiceDefaults_ project. For more information, see [.NET Aspire service defaults](service-defaults.md). By default, the `ConfigureOpenTelemetry` method enables logging, tracing, and metrics for the app. It also adds exporters for these data points so they can be collected by other monitoring tools. @@ -30,7 +30,7 @@ The .NET OpenTelemetry SDK facilitates the export of this telemetry data to a da OpenTelemetry has a [list of known environment variables](https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/) that configure the most important behavior for collecting and exporting telemetry. OpenTelemetry SDKs, including the .NET SDK, support reading these variables. -.NET Aspire apps launch with environment variables that configure the name and ID of the app in exported telemetry and set the address endpoint of the OTLP server to export data. For example: +.NET Aspire projects launch with environment variables that configure the name and ID of the app in exported telemetry and set the address endpoint of the OTLP server to export data. For example: - `OTEL_SERVICE_NAME` = myfrontend - `OTEL_RESOURCE_ATTRIBUTES` = service.instance.id=1a5f9c1e-e5ba-451b-95ee-ced1ee89c168 @@ -40,9 +40,9 @@ The environment variables are automatically set in local development. ## .NET Aspire local development -When you create a .NET Aspire app, the .NET Aspire dashboard provides a UI for viewing app telemetry by default. Telemetry data is sent to the dashboard using OTLP, and the dashboard implements an OTLP server to receive telemetry data and store it in memory. The .NET Aspire debugging workflow is as follows: +When you create a .NET Aspire project, the .NET Aspire dashboard provides a UI for viewing app telemetry by default. Telemetry data is sent to the dashboard using OTLP, and the dashboard implements an OTLP server to receive telemetry data and store it in memory. The .NET Aspire debugging workflow is as follows: -- Developer starts the .NET Aspire app with debugging, presses F5. +- Developer starts the .NET Aspire project with debugging, presses F5. - .NET Aspire dashboard and developer control plane (DCP) start. - App configuration is run in the _AppHost_ project. - OpenTelemetry environment variables are automatically added to .NET projects during app configuration. @@ -51,7 +51,7 @@ When you create a .NET Aspire app, the .NET Aspire dashboard provides a UI for v - Small export intervals (`OTEL_BSP_SCHEDULE_DELAY`, `OTEL_BLRP_SCHEDULE_DELAY`, `OTEL_METRIC_EXPORT_INTERVAL`) so data is quickly available in the dashboard. Small values are used in local development to prioritize dashboard responsiveness over efficiency. - The DCP starts configured projects, containers, and executables. - Once started, apps send telemetry to the dashboard. -- Dashboard displays near real-time telemetry of all .NET Aspire apps. +- Dashboard displays near real-time telemetry of all .NET Aspire projects. All of these steps happen internally, so in most cases the developer simply needs to run the app to see this process in action. diff --git a/docs/fundamentals/testing.md b/docs/fundamentals/testing.md index 488d600d1..a4b5ade15 100644 --- a/docs/fundamentals/testing.md +++ b/docs/fundamentals/testing.md @@ -1,16 +1,16 @@ --- -title: Testing .NET Aspire apps -description: Learn how to test your .NET Aspire apps using the xUnit testing framework. +title: Testing .NET Aspire projects +description: Learn how to test your .NET Aspire projects using the xUnit testing framework. ms.date: 04/22/2024 --- -# Testing .NET Aspire apps +# Testing .NET Aspire projects -In this article, you'll learn how to create a test project, write, and run tests for your .NET Aspire apps. The tests in this article are not unit tests, but rather functional or integration tests. .NET Aspire include an [xUnit testing project template](setup-tooling.md#net-aspire-project-templates) that you can use to test your .NET Aspire apps. The testing project template is based on the xUnit testing framework and includes a sample test that you can use as a starting point for your tests. +In this article, you'll learn how to create a test project, write, and run tests for your .NET Aspire projects. The tests in this article are not unit tests, but rather functional or integration tests. .NET Aspire include an [xUnit testing project template](setup-tooling.md#net-aspire-project-templates) that you can use to test your .NET Aspire projects. The testing project template is based on the xUnit testing framework and includes a sample test that you can use as a starting point for your tests. ## Create a test project -The easiest way to create a .NET Aspire test project is to use the testing project template. If you're starting a new .NET Aspire app and want to include test projects, the [Visual Studio tooling supports that option](setup-tooling.md#create-test-project). If you're adding a test project to an existing .NET Aspire app, you can use the `dotnet new` command to create a test project: +The easiest way to create a .NET Aspire test project is to use the testing project template. If you're starting a new .NET Aspire project and want to include test projects, the [Visual Studio tooling supports that option](setup-tooling.md#create-test-project). If you're adding a test project to an existing .NET Aspire project, you can use the `dotnet new` command to create a test project: ```dotnetcli dotnet new aspire-xunit @@ -18,11 +18,11 @@ dotnet new aspire-xunit ## Explore the test project -The following example test project was created as part of the **.NET Aspire Starter Application** template. If you're unfamiliar with it, see [Quickstart: Build your first .NET Aspire app](../get-started/build-your-first-aspire-app.md). The .NET Aspire test project takes a project reference dependency on the target app host. Consider the template project: +The following example test project was created as part of the **.NET Aspire Starter Application** template. If you're unfamiliar with it, see [Quickstart: Build your first .NET Aspire project](../get-started/build-your-first-aspire-app.md). The .NET Aspire test project takes a project reference dependency on the target app host. Consider the template project: :::code language="xml" source="snippets/testing/AspireApp1/AspireApp1.Tests/AspireApp1.Tests.csproj"::: -The preceding project file is fairly standard. There's a `PackageReference` to the [Aspire.Hosting.Testing](https://www.nuget.org/packages/Aspire.Hosting.Testing) NuGet package, which includes the required types to write tests for .NET Aspire apps. +The preceding project file is fairly standard. There's a `PackageReference` to the [Aspire.Hosting.Testing](https://www.nuget.org/packages/Aspire.Hosting.Testing) NuGet package, which includes the required types to write tests for .NET Aspire projects. The template test project includes a `WebTests` class with a single test fact. The test fact verifies the following scenario: @@ -45,4 +45,4 @@ The preceding code: ## Summary -By using the .NET Aspire testing project template, you can easily create test projects for your .NET Aspire apps. The template project includes a sample test that you can use as a starting point for your tests. The `DistributedApplicationTestingBuilder` follows a familiar pattern to the `WebApplicationFactory` in ASP.NET Core. It allows you to create a test host for your distributed application and run tests against it. +By using the .NET Aspire testing project template, you can easily create test projects for your .NET Aspire projects. The template project includes a sample test that you can use as a starting point for your tests. The `DistributedApplicationTestingBuilder` follows a familiar pattern to the `WebApplicationFactory` in ASP.NET Core. It allows you to create a test host for your distributed application and run tests against it. diff --git a/docs/get-started/add-aspire-existing-app.md b/docs/get-started/add-aspire-existing-app.md index 46e57eea9..b169eeac0 100644 --- a/docs/get-started/add-aspire-existing-app.md +++ b/docs/get-started/add-aspire-existing-app.md @@ -15,7 +15,7 @@ If you have already created a microservices .NET web app, you can add .NET Aspir > - Understand the structure of the existing microservices app. > - Enroll existing projects in .NET Aspire orchestration. > - Understand the changes enrollment makes in the projects. -> - Start the .NET Aspire app. +> - Start the .NET Aspire project. [!INCLUDE [aspire-prereqs](../includes/aspire-prereqs.md)] diff --git a/docs/get-started/aspire-overview.md b/docs/get-started/aspire-overview.md index 4b3196b9f..c58658532 100644 --- a/docs/get-started/aspire-overview.md +++ b/docs/get-started/aspire-overview.md @@ -27,7 +27,7 @@ A _distributed application_ is one that uses computational _resources_ across mu - [**Orchestration**](#orchestration): .NET Aspire provides features for running and connecting multi-project applications and their dependencies for [local development environments](../fundamentals/networking-overview.md). - [**Components**](#net-aspire-components): .NET Aspire components are NuGet packages for commonly used services, such as Redis or Postgres, with standardized interfaces ensuring they connect consistently and seamlessly with your app. -- [**Tooling**](#project-templates-and-tooling): .NET Aspire comes with project templates and tooling experiences for Visual Studio, Visual Studio Code, and the [dotnet CLI](/dotnet/core/tools/) to help you create and interact with .NET Aspire apps. +- [**Tooling**](#project-templates-and-tooling): .NET Aspire comes with project templates and tooling experiences for Visual Studio, Visual Studio Code, and the [dotnet CLI](/dotnet/core/tools/) to help you create and interact with .NET Aspire projects. ## Orchestration @@ -77,11 +77,11 @@ A full list of available components is detailed on the [.NET Aspire components]( ## Project templates and tooling -.NET Aspire apps follow a standardized structure designed around the default .NET Aspire project templates. Most .NET Aspire apps have at least three projects: +.NET Aspire projects follow a standardized structure designed around the default .NET Aspire project templates. Most .NET Aspire projects have at least three projects: - **MyFirstAspireApp**: Your starter app, which could be any common .NET project such as a Blazor UI or Minimal API. You can add more projects to your app as it expands and manage orchestration between them using the **.AppHost** and **.ServiceDefaults** project. - **MyFirstAspireApp.AppHost**: The **.AppHost** project is used to manage the high level orchestration concerns of the app. Orchestration involves putting together various parts of your app, like APIs, service containers, and executables, and setting up how they find and communicate with each other. -- **MyFirstAspireApp.ServiceDefaults**: The **.ServiceDefaults** project contains default .NET Aspire app configurations that can be extended and customized as needed. These configurations include concerns such as setting up health checks, OpenTelemetry settings, and more. +- **MyFirstAspireApp.ServiceDefaults**: The **.ServiceDefaults** project contains default .NET Aspire project configurations that can be extended and customized as needed. These configurations include concerns such as setting up health checks, OpenTelemetry settings, and more. There are currently two .NET Aspire starter templates available to help you get started with this structure: @@ -107,4 +107,4 @@ When added to your _:::no-loc text="Program.cs":::_ file, the preceding code han ## Next steps > [!div class="nextstepaction"] -> [Quickstart: Build your first .NET Aspire app](build-your-first-aspire-app.md) +> [Quickstart: Build your first .NET Aspire project](build-your-first-aspire-app.md) diff --git a/docs/get-started/build-aspire-apps-with-nodejs.md b/docs/get-started/build-aspire-apps-with-nodejs.md index 83296fcad..0302e611a 100644 --- a/docs/get-started/build-aspire-apps-with-nodejs.md +++ b/docs/get-started/build-aspire-apps-with-nodejs.md @@ -4,7 +4,7 @@ description: Learn how to integrate Node.js and npm apps into a .NET Aspire App ms.date: 06/13/2024 --- -# Build .NET Aspire apps with Node.js +# Add Node.js apps to a .NET Aspire project In this article, you learn how to use Node.js and Node Package Manager (`npm`) apps in a .NET Aspire project. The sample app in this article demonstrates [Angular](https://angular.io), [React](https://react.dev/), and [Vue](https://vuejs.org/) client experiences. The following .NET Aspire APIs exist to support these scenarios: @@ -47,10 +47,10 @@ cd samples/AspireWithJavaScript From this directory, there are six child directories described in the following list: - **AspireJavaScript.Angular**: An Angular app that consumes the weather forecast API and displays the data in a table. -- **AspireJavaScript.AppHost**: A .NET Aspire app that orchestrates the other apps in this sample. For more information, see [.NET Aspire orchestration overview](../fundamentals/app-host-overview.md). +- **AspireJavaScript.AppHost**: A .NET Aspire project that orchestrates the other apps in this sample. For more information, see [.NET Aspire orchestration overview](../fundamentals/app-host-overview.md). - **AspireJavaScript.MinimalApi**: An HTTP API that returns randomly generated weather forecast data. - **AspireJavaScript.React**: A React app that consumes the weather forecast API and displays the data in a table. -- **AspireJavaScript.ServiceDefaults**: The default shared project for .NET Aspire apps. For more information, see [.NET Aspire service defaults](../fundamentals/service-defaults.md). +- **AspireJavaScript.ServiceDefaults**: The default shared project for .NET Aspire projects. For more information, see [.NET Aspire service defaults](../fundamentals/service-defaults.md). - **AspireJavaScript.Vue**: A Vue app that consumes the weather forecast API and displays the data in a table. ## Install client dependencies @@ -219,4 +219,4 @@ The client apps are currently configured to run as true SPA apps, and are not co ## Summary -While there are several considerations that are beyond the scope of this article, you learned how to build .NET Aspire apps that use Node.js and Node Package Manager (`npm`). You also learned how to use the APIs to host Node.js apps and apps that execute from a _package.json_ file, respectively. Finally, you learned how to use the `npm` CLI to create Angular, React, and Vue client apps, and how to configure them to run on different ports. +While there are several considerations that are beyond the scope of this article, you learned how to build .NET Aspire projects that use Node.js and Node Package Manager (`npm`). You also learned how to use the APIs to host Node.js apps and apps that execute from a _package.json_ file, respectively. Finally, you learned how to use the `npm` CLI to create Angular, React, and Vue client apps, and how to configure them to run on different ports. diff --git a/docs/includes/visual-studio-file-new.md b/docs/includes/visual-studio-file-new.md index e2cbb1676..ce006b491 100644 --- a/docs/includes/visual-studio-file-new.md +++ b/docs/includes/visual-studio-file-new.md @@ -11,6 +11,6 @@ Visual Studio provides .NET Aspire project templates that handle some initial se 1. On the **Additional information** screen: - Make sure **.NET 8.0 (Long Term Support)** is selected. - Ensure that **Use Redis for caching (requires a supported container runtime)** is checked and select **Create**. - - Optionally, you can select **Create a tests project**. For more information, see [Testing .NET Aspire apps](../fundamentals/testing.md). + - Optionally, you can select **Create a tests project**. For more information, see [Testing .NET Aspire projects](../fundamentals/testing.md). Visual Studio creates a new solution that is structured to use .NET Aspire. diff --git a/docs/messaging/messaging-components.md b/docs/messaging/messaging-components.md index 24808982f..817fa7387 100644 --- a/docs/messaging/messaging-components.md +++ b/docs/messaging/messaging-components.md @@ -476,17 +476,17 @@ The sample app is now ready for testing. Verify that the data submitted to the A :::zone pivot="visual-studio" -1. Launch the .NET Aspire app by selecting the **Start** debugging button, or by pressing F5. The .NET Aspire dashboard app should open in the browser. +1. Launch the .NET Aspire project by selecting the **Start** debugging button, or by pressing F5. The .NET Aspire dashboard app should open in the browser. :::zone-end :::zone pivot="vscode" -1. Launch the .NET Aspire app by selecting the **Start** debugging button, or by pressing F5. The .NET Aspire dashboard app should open in the browser. +1. Launch the .NET Aspire project by selecting the **Start** debugging button, or by pressing F5. The .NET Aspire dashboard app should open in the browser. :::zone-end :::zone pivot="dotnet-cli" -1. Launch the .NET Aspire app by running `dotnet run --project AspireSample.AppHost`. The .NET Aspire dashboard app should open in the browser. +1. Launch the .NET Aspire project by running `dotnet run --project AspireSample.AppHost`. The .NET Aspire dashboard app should open in the browser. :::zone-end diff --git a/docs/real-time/azure-signalr-scenario.md b/docs/real-time/azure-signalr-scenario.md index c4639d003..327b4f4aa 100644 --- a/docs/real-time/azure-signalr-scenario.md +++ b/docs/real-time/azure-signalr-scenario.md @@ -7,7 +7,7 @@ ms.date: 04/18/2024 # .NET Aspire support for Azure SignalR Service -In this article, you learn how to use .NET Aspire to express an Azure SignalR Service resource. Demonstrating how to write a SignalR app is beyond the scope of this article. Instead, you explore an app that's already been written and how it's wired up with .NET Aspire. Like other Azure resources within the .NET Aspire [app model](../fundamentals/app-host-overview.md#define-the-app-model), you benefit from simple provisioning and deployment with the Azure Developer CLI (`azd`). For more information, see [Deploy a .NET Aspire app to Azure Container Apps using the `azd` (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md). +In this article, you learn how to use .NET Aspire to express an Azure SignalR Service resource. Demonstrating how to write a SignalR app is beyond the scope of this article. Instead, you explore an app that's already been written and how it's wired up with .NET Aspire. Like other Azure resources within the .NET Aspire [app model](../fundamentals/app-host-overview.md#define-the-app-model), you benefit from simple provisioning and deployment with the Azure Developer CLI (`azd`). For more information, see [Deploy a .NET Aspire project to Azure Container Apps using the `azd` (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md). ## Hub host diff --git a/docs/reference/aspire-faq.yml b/docs/reference/aspire-faq.yml index 0cd539c66..e56b740d0 100644 --- a/docs/reference/aspire-faq.yml +++ b/docs/reference/aspire-faq.yml @@ -72,7 +72,7 @@ sections: - question: | What's the relationship between .NET Aspire and Kubernetes? answer: | - .NET Aspire makes it easy to develop distributed applications that can be orchestrated on your local development environment as executables and containers. Kubernetes is a technology that orchestrates and manages containers across multiple machines. .NET Aspire applications can produce a [manifest](../deployment/manifest-format.md) that tool authors can use to produce artifacts for deployment to Kubernetes. In essence, Kubernetes is a deployment target for .NET Aspire applications. + .NET Aspire makes it easy to develop distributed applications that can be orchestrated on your local development environment as executables and containers. Kubernetes is a technology that orchestrates and manages containers across multiple machines. .NET Aspire projects can produce a [manifest](../deployment/manifest-format.md) that tool authors can use to produce artifacts for deployment to Kubernetes. In essence, Kubernetes is a deployment target for .NET Aspire projects. - question: | Are worker services supported in .NET Aspire? answer: | @@ -91,5 +91,5 @@ additionalContent: | To learn more about networking and functions: * [.NET Aspire overview](../get-started/aspire-overview.md) - * [Build your first .NET Aspire app](../get-started/build-your-first-aspire-app.md) + * [Build your first .NET Aspire project](../get-started/build-your-first-aspire-app.md) * [.NET Aspire components](../fundamentals/components-overview.md) diff --git a/docs/service-discovery/overview.md b/docs/service-discovery/overview.md index 57616ad12..57b2e80a0 100644 --- a/docs/service-discovery/overview.md +++ b/docs/service-discovery/overview.md @@ -7,7 +7,7 @@ ms.topic: quickstart # .NET Aspire service discovery -In this article, you learn how service discovery works within a .NET Aspire app. .NET Aspire includes functionality for configuring service discovery at development and testing time. Service discovery functionality works by providing configuration in the format expected by the _configuration-based endpoint resolver_ from the .NET Aspire AppHost project to the individual service projects added to the application model. For more information, see [Service discovery in .NET](/dotnet/core/extensions/service-discovery). +In this article, you learn how service discovery works within a .NET Aspire project. .NET Aspire includes functionality for configuring service discovery at development and testing time. Service discovery functionality works by providing configuration in the format expected by the _configuration-based endpoint resolver_ from the .NET Aspire AppHost project to the individual service projects added to the application model. For more information, see [Service discovery in .NET](/dotnet/core/extensions/service-discovery). ## Implicit service discovery by reference @@ -24,7 +24,7 @@ var frontend = builder.AddProject("frontend") .WithReference(catalog); ``` -In the preceding example, the _frontend_ project references the _catalog_ project and the _basket_ project. The two calls instruct the .NET Aspire application to pass service discovery information for the referenced projects (_catalog_, and _basket_) into the _frontend_ project. +In the preceding example, the _frontend_ project references the _catalog_ project and the _basket_ project. The two calls instruct the .NET Aspire project to pass service discovery information for the referenced projects (_catalog_, and _basket_) into the _frontend_ project. ## Named endpoints diff --git a/docs/storage/azure-storage-components.md b/docs/storage/azure-storage-components.md index a5f801e9e..c68b073d1 100644 --- a/docs/storage/azure-storage-components.md +++ b/docs/storage/azure-storage-components.md @@ -109,7 +109,7 @@ After the operation completes successfully, you have two options moving forward: ## Create the sample solution -Create a .NET Aspire app using either Visual Studio or the .NET CLI. +Create a .NET Aspire project using either Visual Studio or the .NET CLI. ## [Visual Studio](#tab/visual-studio) @@ -125,7 +125,7 @@ Visual Studio creates a new ASP.NET Core solution that is structured to use .NET ## [.NET CLI](#tab/net-cli) -Use the [`dotnet new`](/dotnet/core/tools/dotnet-new) command to create a new .NET Aspire app: +Use the [`dotnet new`](/dotnet/core/tools/dotnet-new) command to create a new .NET Aspire project: ```dotnetcli dotnet new aspire-starter --name AspireStorage @@ -351,7 +351,7 @@ The sample app is now ready for testing. Verify that the submitted form data is ## [Visual Studio](#tab/visual-studio) -1. Press the run button at the top of Visual Studio to launch your .NET Aspire app dashboard in the browser. +1. Press the run button at the top of Visual Studio to launch your .NET Aspire project dashboard in the browser. 1. On the resources page, in the **aspirestorage.web** row, click the link in the **Endpoints** column to open the UI of your app. :::image type="content" source="media/support-app.png" lightbox="media/support-app.png" alt-text="A screenshot showing the home page of the .NET Aspire support application."::: diff --git a/docs/toc.yml b/docs/toc.yml index 211a440e2..763c4a5fd 100644 --- a/docs/toc.yml +++ b/docs/toc.yml @@ -265,9 +265,9 @@ items: items: - name: Introduction to .NET Aspire href: /training/modules/introduction-dotnet-aspire - - name: Create a .NET Aspire application + - name: Create a .NET Aspire project href: /training/modules/create-aspire-applications - - name: Use telemetry in a .NET Aspire app + - name: Use telemetry in a .NET Aspire project href: /training/modules/use-telemetry-dotnet-aspire - name: Resources diff --git a/docs/troubleshooting/allow-unsecure-transport.md b/docs/troubleshooting/allow-unsecure-transport.md index 2144a0719..dd8b3dde5 100644 --- a/docs/troubleshooting/allow-unsecure-transport.md +++ b/docs/troubleshooting/allow-unsecure-transport.md @@ -1,16 +1,16 @@ --- title: Allow unsecure transport in .NET Aspire -description: Learn how to allow unsecure transport in .NET Aspire applications. +description: Learn how to allow unsecure transport in .NET Aspire projects. ms.date: 04/09/2024 --- # Allow unsecure transport in .NET Aspire -Starting with .NET Aspire preview 5, the app host will crash if an `applicationUrl` is configured with an unsecure transport (non-TLS `http`) protocol. This is a security feature to prevent accidental exposure of sensitive data. However, there are scenarios where you might need to allow unsecure transport. This article explains how to allow unsecure transport in .NET Aspire applications. +Starting with .NET Aspire preview 5, the app host will crash if an `applicationUrl` is configured with an unsecure transport (non-TLS `http`) protocol. This is a security feature to prevent accidental exposure of sensitive data. However, there are scenarios where you might need to allow unsecure transport. This article explains how to allow unsecure transport in .NET Aspire projects. ## Symptoms -When you run a .NET Aspire application with an `applicationUrl` configured with an unsecure transport protocol, you might see the following error message: +When you run a .NET Aspire project with an `applicationUrl` configured with an unsecure transport protocol, you might see the following error message: ```Output The 'applicationUrl' setting must be an https address unless the diff --git a/docs/troubleshooting/name-is-already-in-use.md b/docs/troubleshooting/name-is-already-in-use.md index 93cbc68c5..db794064f 100644 --- a/docs/troubleshooting/name-is-already-in-use.md +++ b/docs/troubleshooting/name-is-already-in-use.md @@ -14,7 +14,7 @@ This article describes several techniques to avoid this problem. ## Symptoms -When deploying a .NET Aspire app to Azure, the resources in the [app model](../fundamentals/app-host-overview.md#define-the-app-model) are transformed into Azure resources. Some Azure resources have globally scoped names, such as Azure App Configuration, where all instances are in the `[name].azconfig.io` global namespace. +When deploying a .NET Aspire project to Azure, the resources in the [app model](../fundamentals/app-host-overview.md#define-the-app-model) are transformed into Azure resources. Some Azure resources have globally scoped names, such as Azure App Configuration, where all instances are in the `[name].azconfig.io` global namespace. The value of `[name]` is derived from the .NET Aspire resource name, along with random characters based on the resource group name. However, the generated string may exceed the allowable length for the resource name in App Configuration. As a result, some characters are truncated to ensure compliance. diff --git a/docs/whats-new/dotnet-docs-aspire-mod0.md b/docs/whats-new/dotnet-docs-aspire-mod0.md index 5468ad1e2..37e1ed3d1 100644 --- a/docs/whats-new/dotnet-docs-aspire-mod0.md +++ b/docs/whats-new/dotnet-docs-aspire-mod0.md @@ -16,7 +16,7 @@ Welcome to what's new in the .NET Aspire docs for March 2024. This article lists - [.NET Aspire setup and tooling](../fundamentals/setup-tooling.md) - Add details about container runtime - [.NET Aspire orchestration overview](../fundamentals/app-host-overview.md) - Add details for shortcuts - [.NET Aspire dashboard overview](../fundamentals/dashboard/overview.md) - Add details for shortcuts -- [Persist .NET Aspire app data using volumes](../fundamentals/persist-data-volumes.md) - Add details for shortcuts +- [Persist .NET Aspire project data using volumes](../fundamentals/persist-data-volumes.md) - Add details for shortcuts ## Storage @@ -32,7 +32,7 @@ Welcome to what's new in the .NET Aspire docs for March 2024. This article lists ### New articles -- [Tutorial: Deploy a .NET Aspire app with a SQL Server Database to Azure](../database/sql-server-component-deployment.md) +- [Tutorial: Deploy a .NET Aspire project with a SQL Server Database to Azure](../database/sql-server-component-deployment.md) ### Updated articles @@ -52,9 +52,9 @@ Welcome to what's new in the .NET Aspire docs for March 2024. This article lists ### Updated articles - [.NET Aspire manifest format for deployment tool builders](../deployment/manifest-format.md) - Add details for shortcuts -- [Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md) - add tags for azd content tracking -- [Tutorial: Deploy a .NET Aspire app using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) - add tags for azd content tracking -- [Deploy a .NET Aspire app to Azure Container Apps](../deployment/azure/aca-deployment.md) - add tags for azd content tracking +- [Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md) - add tags for azd content tracking +- [Tutorial: Deploy a .NET Aspire project using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) - add tags for azd content tracking +- [Deploy a .NET Aspire project to Azure Container Apps](../deployment/azure/aca-deployment.md) - add tags for azd content tracking ## Community contributors diff --git a/docs/whats-new/dotnet-docs-aspire-mod1.md b/docs/whats-new/dotnet-docs-aspire-mod1.md index 6972fac7b..ef164f790 100644 --- a/docs/whats-new/dotnet-docs-aspire-mod1.md +++ b/docs/whats-new/dotnet-docs-aspire-mod1.md @@ -14,7 +14,7 @@ Welcome to what's new in the .NET Aspire docs for April 2024. This article lists ### Updated articles - [.NET Aspire overview](../get-started/aspire-overview.md) - Fix invalidated xref's since API updates -- [Build .NET Aspire apps with Node.js](../get-started/build-aspire-apps-with-nodejs.md) +- [Add Node.js apps to a .NET Aspire project](../get-started/build-aspire-apps-with-nodejs.md) - nit: fixed spelling - Update the nodejs content to align with the recent updates to the sample - Fix the env var format for service endpoints @@ -40,7 +40,7 @@ Welcome to what's new in the .NET Aspire docs for April 2024. This article lists - More issues - Update setup-tooling.md (typo) - [Health checks in .NET Aspire](../fundamentals/health-checks.md) - Update health-checks verbiage -- [Persist .NET Aspire app data using volumes](../fundamentals/persist-data-volumes.md) +- [Persist .NET Aspire project data using volumes](../fundamentals/persist-data-volumes.md) - Local code snippets and correct persisted volumes - Try a redirect @@ -75,7 +75,7 @@ Welcome to what's new in the .NET Aspire docs for April 2024. This article lists - Add clarifying details for SQL Server and database workflow - Corrected PostgreSQL typo - Try a redirect -- [Tutorial: Deploy a .NET Aspire app with a SQL Server Database to Azure](../database/sql-server-component-deployment.md) - Updates and fixes for SQL deployment +- [Tutorial: Deploy a .NET Aspire project with a SQL Server Database to Azure](../database/sql-server-component-deployment.md) - Updates and fixes for SQL deployment ## Messaging @@ -110,9 +110,9 @@ Welcome to what's new in the .NET Aspire docs for April 2024. This article lists ### Updated articles -- [Deploy a .NET Aspire app to Azure Container Apps](../deployment/azure/aca-deployment.md) - Aspire vs deploy +- [Deploy a .NET Aspire project to Azure Container Apps](../deployment/azure/aca-deployment.md) - Aspire vs deploy - [Local Azure provisioning](../deployment/azure/local-provisioning.md) - Remove misplaced provisioning content, it belonged in local -- [Tutorial: Deploy a .NET Aspire app using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) +- [Tutorial: Deploy a .NET Aspire project using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) - Address multiple issues - Correct typo in naming of the directory for azure devops pipeline deployment documentations - Typo "Create a Azure DevOps"→"Create an Azure DevOps" diff --git a/docs/whats-new/dotnet-docs-aspire-mod2.md b/docs/whats-new/dotnet-docs-aspire-mod2.md index 8f2b1379c..23076ebd7 100644 --- a/docs/whats-new/dotnet-docs-aspire-mod2.md +++ b/docs/whats-new/dotnet-docs-aspire-mod2.md @@ -17,10 +17,10 @@ Welcome to what's new in the .NET Aspire docs for May 2024. This article lists s - Fixes typo in .NET Aspire Overview - Help more clearly define local dev. - typo -- [Build .NET Aspire apps with Node.js](../get-started/build-aspire-apps-with-nodejs.md) +- [Add Node.js apps to a .NET Aspire project](../get-started/build-aspire-apps-with-nodejs.md) - Update build-aspire-apps-with-nodejs.md - Fix screen capture and TS file ref. -- [Quickstart: Build your first .NET Aspire app](../get-started/build-your-first-aspire-app.md) +- [Quickstart: Build your first .NET Aspire project](../get-started/build-your-first-aspire-app.md) - Update build-your-first-aspire-app.md to highlight the correct line - Address all issues in #720 - [Tutorial: Add .NET Aspire to an existing .NET app](../get-started/add-aspire-existing-app.md) - Add content for VS Code and .NET CLI to tutorial @@ -55,7 +55,7 @@ Welcome to what's new in the .NET Aspire docs for May 2024. This article lists s - Change trace detail view -> page - Fix #810 - [Health checks in .NET Aspire](../fundamentals/health-checks.md) - Placeholder for .NET Aspire preview 7. -- [Persist .NET Aspire app data using volumes](../fundamentals/persist-data-volumes.md) - Fix PostgreSQL typo in persist-data-volumes.md +- [Persist .NET Aspire project data using volumes](../fundamentals/persist-data-volumes.md) - Fix PostgreSQL typo in persist-data-volumes.md - [Security considerations for running the .NET Aspire dashboard](../fundamentals/dashboard/security-considerations.md) - Updates to .NET Aspire dashboard content - Add missing image updates @@ -141,7 +141,7 @@ Welcome to what's new in the .NET Aspire docs for May 2024. This article lists s ### New articles -- [Tutorial: Deploy a .NET Aspire app with a Redis Cache to Azure](../caching/caching-components-deployment.md) +- [Tutorial: Deploy a .NET Aspire project with a Redis Cache to Azure](../caching/caching-components-deployment.md) ### Updated articles @@ -160,24 +160,24 @@ Welcome to what's new in the .NET Aspire docs for May 2024. This article lists s ### New articles -- [Deploy a .NET Aspire app to Azure Container Apps using Visual Studio](../deployment/azure/aca-deployment-visual-studio.md) +- [Deploy a .NET Aspire project to Azure Container Apps using Visual Studio](../deployment/azure/aca-deployment-visual-studio.md) ### Updated articles - [.NET Aspire deployments](../deployment/overview.md) - Edit pass on deployment doc - Minor casing fix -- [Deploy a .NET Aspire app to Azure Container Apps](../deployment/azure/aca-deployment.md) +- [Deploy a .NET Aspire project to Azure Container Apps](../deployment/azure/aca-deployment.md) - Deployment fixes - deployment refactoring -- [Deploy a .NET Aspire app to Azure Container Apps using the Azure Developer CLI (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md) +- [Deploy a .NET Aspire project to Azure Container Apps using the Azure Developer CLI (in-depth guide)](../deployment/azure/aca-deployment-azd-in-depth.md) - Update aca-deployment-azd-in-depth.md - Add missing dotnet cli command argument - Deployment fixes -- [Deploy a .NET Aspire app to Azure Container Apps using Visual Studio](../deployment/azure/aca-deployment-visual-studio.md) +- [Deploy a .NET Aspire project to Azure Container Apps using Visual Studio](../deployment/azure/aca-deployment-visual-studio.md) - Deployment fixes - deployment refactoring - [Local Azure provisioning](../deployment/azure/local-provisioning.md) - Fix AzureProvisioner config docs -- [Tutorial: Deploy a .NET Aspire app using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) +- [Tutorial: Deploy a .NET Aspire project using the Azure Developer CLI and GitHub Actions](../deployment/azure/aca-deployment-github-actions.md) - Add link to supporting content for `az group delete` and help macOS users create .github - fix deployment yaml diff --git a/docs/whats-new/preview-3.md b/docs/whats-new/preview-3.md index 531e07115..ddb00e254 100644 --- a/docs/whats-new/preview-3.md +++ b/docs/whats-new/preview-3.md @@ -41,7 +41,7 @@ aspire 8.0.0-preview.3.24105.21/8.0.100 SDK 8.0.100, VS 17. ### Update existing apps -For existing .NET Aspire apps, after installing the latest workload, update all .NET Aspire package references to: +For existing .NET Aspire projects, after installing the latest workload, update all .NET Aspire package references to: - `8.0.0-preview.3.24105.21` @@ -277,7 +277,7 @@ builder.AddAzureCosmosDB("db", static settings => When using the Cosmos DB emulator, you can ignore the certificate validation by setting the `IgnoreEmulatorCertificate` property to `true`. We are currently working with the Cosmos team to remove the need to set `IgnoreEmulatorCertificate` so this customization for settings may not be required in the future. -When deployed, `azd` will automatically provision the Cosmos DB resource and create the database as defined in the .NET Aspire application model. +When deployed, `azd` will automatically provision the Cosmos DB resource and create the database as defined in the .NET Aspire project model. ### `StackExchange.Redis` now has logging @@ -410,9 +410,9 @@ builder.AddKeyedRedis("redis-cart"); The .NET Aspire samples are located in , not the main Aspire repo. New samples for preview 3 include: -- [AspireWithJavaScript](https://github.com/dotnet/aspire-samples/tree/main/samples/AspireWithJavaScript) demonstrates an approach for integrating several Node.js apps into a .NET Aspire application, including Angular, React, and Vue. -- [ClientAppsIntegration](https://github.com/dotnet/aspire-samples/tree/main/samples/ClientAppsIntegration) demonstrates working with client apps such as WinForms, WPF, etc., in a .NET Aspire app, such that the client app is launched along with the AppHost project, can resolve services via service discovery, and logs, traces, and metrics via OpenTelemetry to the dashboard. -- [Persistent Volume Mount](https://github.com/dotnet/aspire-samples/tree/main/samples/VolumeMount) demonstrates how to configure a SQL Server container to use a persistent volume mount in .NET Aspire, so that the data is persisted across app launches. This method can be used to persist data across instances of other container types configured in .NET Aspire apps too, e.g. PostgreSQL, Redis, etc. +- [AspireWithJavaScript](https://github.com/dotnet/aspire-samples/tree/main/samples/AspireWithJavaScript) demonstrates an approach for integrating several Node.js apps into a .NET Aspire project, including Angular, React, and Vue. +- [ClientAppsIntegration](https://github.com/dotnet/aspire-samples/tree/main/samples/ClientAppsIntegration) demonstrates working with client apps such as WinForms, WPF, etc., in a .NET Aspire project, such that the client app is launched along with the AppHost project, can resolve services via service discovery, and logs, traces, and metrics via OpenTelemetry to the dashboard. +- [Persistent Volume Mount](https://github.com/dotnet/aspire-samples/tree/main/samples/VolumeMount) demonstrates how to configure a SQL Server container to use a persistent volume mount in .NET Aspire, so that the data is persisted across app launches. This method can be used to persist data across instances of other container types configured in .NET Aspire projects too, e.g. PostgreSQL, Redis, etc. ## Deployment to Azure using `azd` @@ -429,7 +429,7 @@ var azSqlServer = builder.AddAzureSqlServer("azsql").AddDatabase("azsqldb"); ## Add templates for _AppHost_ and _ServiceDefaults_ projects -For those wishing to add .NET Aspire functionality to an existing solution, you can use the new templates for the _AppHost_ and _ServiceDefault_ projects. These are the same projects included in the empty .NET Aspire application template. They can be added through Visual Studio _Add New Project_ or via the command line using: +For those wishing to add .NET Aspire functionality to an existing solution, you can use the new templates for the _AppHost_ and _ServiceDefault_ projects. These are the same projects included in the empty .NET Aspire project template. They can be added through Visual Studio _Add New Project_ or via the command line using: ```console dotnet new aspire-apphost diff --git a/docs/whats-new/preview-4.md b/docs/whats-new/preview-4.md index 9fc4a1812..0f0f867a0 100644 --- a/docs/whats-new/preview-4.md +++ b/docs/whats-new/preview-4.md @@ -63,7 +63,7 @@ With preview 4, we have introduced a screen reader compatible table view for dis ## Databases and Entity Framework improvements -In addition to new APIs, the .NET Aspire preview 4 release includes several improvements to the Entity Framework components. These improvements are designed to make it easier to configure and use Entity Framework in .NET Aspire applications. +In addition to new APIs, the .NET Aspire preview 4 release includes several improvements to the Entity Framework components. These improvements are designed to make it easier to configure and use Entity Framework in .NET Aspire projects. ### More database management tools @@ -99,7 +99,7 @@ Since these new methods provide a simpler way to configure the `DbContext`, the ### Entity Framework migrations -We've improved the process of using [EF Core tooling to create migrations](/ef/core/managing-schemas/migrations/) within .NET Aspire apps. Previously, EF Core tooling would fail, displaying an error that the database connection string is missing. This error occurred because EF Core tooling initiated the app, not .NET Aspire hosting, resulting in a failure to inject a connection string into the app. In preview 4, .NET Aspire detects whether a project is launched with EF Core tooling and disables connection string validation, allowing migrations to be successfully created. +We've improved the process of using [EF Core tooling to create migrations](/ef/core/managing-schemas/migrations/) within .NET Aspire projects. Previously, EF Core tooling would fail, displaying an error that the database connection string is missing. This error occurred because EF Core tooling initiated the app, not .NET Aspire hosting, resulting in a failure to inject a connection string into the app. In preview 4, .NET Aspire detects whether a project is launched with EF Core tooling and disables connection string validation, allowing migrations to be successfully created. Another challenge with EF Core migrations is applying them to a transient database that starts up with the app. An approach we've been exploring involves adding a .NET background worker resource to the .NET Aspire solution. This worker executes migrations when the app host starts. @@ -670,7 +670,7 @@ In addition to new features, azd will automatically create secrets in Azure Cont ## Visual Studio Publish to Azure -This release we've enabled a Visual Studio publish experience for .NET Aspire applications. This new deployment experience enables a single right-click-publish gesture that results in *all* of the nodes of your .NET Aspire project being published as individual Azure Container Apps in an Azure Container Apps Environment, ideal for dev/test scenarios. Even better - the publishing experience in Visual Studio uses `azd` under the hood, so you'll be able to publish .NET Aspire apps directly from Visual Studio to any `azd` environment you have running in Azure. +This release we've enabled a Visual Studio publish experience for .NET Aspire projects. This new deployment experience enables a single right-click-publish gesture that results in *all* of the nodes of your .NET Aspire project being published as individual Azure Container Apps in an Azure Container Apps Environment, ideal for dev/test scenarios. Even better - the publishing experience in Visual Studio uses `azd` under the hood, so you'll be able to publish .NET Aspire projects directly from Visual Studio to any `azd` environment you have running in Azure. :::image type="content" source="media/preview-4/aspire-azd-publish.gif" lightbox="media/preview-4/aspire-azd-publish.gif" alt-text=".NET Aspire right-click publish in Visual Studio"::: @@ -692,7 +692,7 @@ When using Podman, the console logs for a container don't show up in the .NET As **Workaround**: You can add a symlink from `docker` to `podman` as described in [issue comment](https://github.com/dotnet/aspire/issues/2701#issuecomment-1987227953) or you can simply alias Docker to Podman (`alias docker=podman`) as mentioned in [What is Podman](https://docs.podman.io/en/latest/index.html#what-is-podman). -### When running .NET Aspire app, we sometimes see `KubeConfigException : kubeconfig file not found when the host is trying to start up` +### When running .NET Aspire project, we sometimes see `KubeConfigException : kubeconfig file not found when the host is trying to start up` As described in [issue #2542](https://github.com/dotnet/aspire/issues/2542), you might see a `KubeConfigException` sometimes when running the Aspire application. For more information, see [issue #2542 comment](https://github.com/dotnet/aspire/issues/2542#issuecomment-1974253166) for a description of why this issue might likely happen. diff --git a/docs/whats-new/preview-5.md b/docs/whats-new/preview-5.md index cadd230d8..b045fbcf1 100644 --- a/docs/whats-new/preview-5.md +++ b/docs/whats-new/preview-5.md @@ -81,7 +81,7 @@ dotnet add package Aspire.Hosting.AppHost --prerelease In addition to the package reference, some APIs were updated in preview 5. For more information, see [Application model changes](#application-model-changes). Some parameter names changed, while others were removed. -All .NET Aspire NuGet package references should be upgraded to `8.0.0-preview.5.24201.12`. If you've created .NET Aspire apps using any of the previous templates, you'll want to update the _Extensions.cs_ file of the service defaults project to reflect the new APIs, as well as update the project file to reference the new NuGet packages. See [service defaults](../fundamentals/service-defaults.md) for the latest source updates. +All .NET Aspire NuGet package references should be upgraded to `8.0.0-preview.5.24201.12`. If you've created .NET Aspire projects using any of the previous templates, you'll want to update the _Extensions.cs_ file of the service defaults project to reflect the new APIs, as well as update the project file to reference the new NuGet packages. See [service defaults](../fundamentals/service-defaults.md) for the latest source updates. Additional considerations for upgrading to preview 5 include: @@ -365,7 +365,7 @@ For Preview 5 we've improved support with our Visual Studio family of products f ### Visual Studio Code C# DevKit tooling -With the April release of C# Dev Kit, you can now launch all projects in a .NET Aspire from Visual Studio Code. To launch your .NET Aspire application, simply Ctrl-F5 (Run without debugging). This will launch the app host project and all the associated projects in your .NET Aspire application (front-end and APIs). Similarly, you can debug your .NET Aspire application, simply F5 (Start debugging) and all the projects will attach to the debugger, allowing you to have breakpoints set across projects and each one will be hit when appropriate. +With the April release of C# Dev Kit, you can now launch all projects in a .NET Aspire from Visual Studio Code. To launch your .NET Aspire project, simply Ctrl-F5 (Run without debugging). This will launch the app host project and all the associated projects in your .NET Aspire project (front-end and APIs). Similarly, you can debug your .NET Aspire project, simply F5 (Start debugging) and all the projects will attach to the debugger, allowing you to have breakpoints set across projects and each one will be hit when appropriate. ### Visual Studio tooling updates @@ -373,7 +373,7 @@ In Visual Studio 17.10 we've continued to improve the end-to-end experience for :::image type="content" source="media/preview-5/remove-environment.gif" lightbox="media/preview-5/remove-environment.gif" alt-text="Removing a local and live Azure environment"::: -This release of Visual Studio also adds support for the Azure Provisioning features in the release. When you're using Azure resources in a .NET Aspire app, like OpenAI, and need to have use the remote resources during your local development, Visual Studio gives you a way of creating or selecting an existing resource group in which those resources can be provisioned. This animation shows the process of adding OpenAI support to an Aspire app, then running the app only to learn the resources need to be created with the warnings in the Aspire dashboard. At this point, you can flip back into Visual Studio and use Connected Services to set up Azure provisioning so your dev-time resources can be created on the fly. +This release of Visual Studio also adds support for the Azure Provisioning features in the release. When you're using Azure resources in a .NET Aspire project, like OpenAI, and need to have use the remote resources during your local development, Visual Studio gives you a way of creating or selecting an existing resource group in which those resources can be provisioned. This animation shows the process of adding OpenAI support to an Aspire app, then running the app only to learn the resources need to be created with the warnings in the Aspire dashboard. At this point, you can flip back into Visual Studio and use Connected Services to set up Azure provisioning so your dev-time resources can be created on the fly. :::image type="content" source="media/preview-5/aspire-preview-5-relnotes.gif" lightbox="media/preview-5/aspire-preview-5-relnotes.gif" alt-text="Using Connected Services to configure Azure provisioning"::: @@ -415,13 +415,13 @@ This makes it clear that we are adding a "client" object to the `WebApplicationB ## Azure improvements -The primary focus of the Azure improvements in preview 5 is to make it easier to use Azure resources in your .NET Aspire application. This includes improvements to the Azure provisioning libraries, support for local development with Azure resources, and other Azure-related improvements. +The primary focus of the Azure improvements in preview 5 is to make it easier to use Azure resources in your .NET Aspire project. This includes improvements to the Azure provisioning libraries, support for local development with Azure resources, and other Azure-related improvements. ### Azure provisioning libraries In preview 5 the Azure-specific extensions for .NET Aspire have adopted the Azure Provisioning libraries being developed by the Azure SDK team. The Azure Provisioning libraries allow as to use a C# object model to declare Azure resources and at deployment time translate that object model into Bicep which is then used to automate deployment. -If you are already using Azure-based resources with your .NET Aspire application the APIs you use today continue to work. For example the following code creates an Azure Cosmos database and wires up the connection string to your application. +If you are already using Azure-based resources with your .NET Aspire project the APIs you use today continue to work. For example the following code creates an Azure Cosmos database and wires up the connection string to your application. ```csharp var builder = DistributedApplication.CreateBuilder(args); @@ -808,7 +808,7 @@ We have added support for Docker build arguments in the manifest. This is useful As known issues for `preview-5` are discovered, they will be listed here. -When running a .NET Aspire app, we sometimes see that the run session fails to start and displays the error "context deadline exceeded." With this occurs, the error output resembles the following: +When running a .NET Aspire project, we sometimes see that the run session fails to start and displays the error "context deadline exceeded." With this occurs, the error output resembles the following: ```Output run session could not be started: {"Executable": {"name":""}, "Reconciliation": , "error": "Put \": context deadline exceeded"}" diff --git a/docs/whats-new/preview-6.md b/docs/whats-new/preview-6.md index 6a2056212..7e30c41a4 100644 --- a/docs/whats-new/preview-6.md +++ b/docs/whats-new/preview-6.md @@ -46,9 +46,9 @@ Data displayed in the dashboard can be sensitive. For example, configuration can :::image type="content" source="media/preview-6/login.png" lightbox="media/preview-6/login.png" alt-text=".NET Aspire dashboard login page"::: -If you run your .NET Aspire apps from Visual Studio or the C# Dev Kit for Visual Studio Code, then you'll never see the login page. Aspire tooling has been updated to log you in automatically. +If you run your .NET Aspire projects from Visual Studio or the C# Dev Kit for Visual Studio Code, then you'll never see the login page. Aspire tooling has been updated to log you in automatically. -If you run your .NET Aspire apps from the command line, you'll need to login the first time you access the dashboard. The required token is printed in console output, so copy and paste it into the login page and click Login. A persistent auth cookie is saved to the browser. Hopefully you won't need to see the login page often. +If you run your .NET Aspire projects from the command line, you'll need to login the first time you access the dashboard. The required token is printed in console output, so copy and paste it into the login page and click Login. A persistent auth cookie is saved to the browser. Hopefully you won't need to see the login page often. :::image type="content" source="media/preview-6/console-token.png" lightbox="media/preview-6/console-token.png" alt-text=".NET Aspire console with login token highlighted"::: @@ -155,7 +155,7 @@ public class WebTests The above example shows how to create a `DistributedApplicationTestingBuilder` in order to bootstrap the app host project and run tests against it. There's also an easy way to create an `HttpClient` that is configured to make requests to resources in the app host project. -For more information, see [Testing .NET Aspire apps](../fundamentals/testing.md). +For more information, see [Testing .NET Aspire projects](../fundamentals/testing.md). ## Templates