Skip to content

Commit 877ab81

Browse files
committed
Added SKU changes, fixed #3144
1 parent dcbe4b5 commit 877ab81

File tree

3 files changed

+60
-0
lines changed

3 files changed

+60
-0
lines changed
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
---
2+
title: "Breaking change - Change the default SKU used for creating a new Azure SQL database"
3+
description: "Learn about the breaking change in .NET Aspire 9.3 where the default SKU for Azure SQL database deployment now uses the free offer."
4+
ms.date: 5/7/2025
5+
ai-usage: ai-assisted
6+
ms.custom: https://github.com/dotnet/docs-aspire/issues/3144
7+
---
8+
9+
# Change the default SKU used for creating a new Azure SQL database
10+
11+
The default SKU for deploying a new Azure SQL database has been updated to take advantage of the Azure SQL Database free offer. This change helps avoid unexpected monthly costs by pausing the database when free offer limits are reached. A new method, `WithSku`, has also been introduced to allow customization of the SKU during deployment.
12+
13+
## Version introduced
14+
15+
.NET Aspire 9.3
16+
17+
## Previous behavior
18+
19+
The Azure SQL database was deployed with a default SKU that did not utilize the Azure SQL Database free offer. This could result in unexpected monthly costs if the database usage exceeded the free tier limits.
20+
21+
## New behavior
22+
23+
The Azure SQL database now deploys with the default SKU `GP_S_Gen5_2` (General Purpose Serverless) and the Azure SQL Database free offer enabled. The database pauses automatically when free offer limits are reached, preventing unexpected costs. Additionally, the `WithSku` method allows you to specify a different SKU if needed.
24+
25+
Example usage of the new `WithSku` method:
26+
27+
```csharp
28+
var database = resourceBuilder
29+
.AddDatabase("MyDatabase")
30+
.WithSku("GP_S_Gen5_4");
31+
```
32+
33+
## Type of breaking change
34+
35+
This is a [behavioral change](../../categories.md#behavioral-change).
36+
37+
## Reason for change
38+
39+
This change ensures that deployments take advantage of the Azure SQL Database free offer, reducing the risk of incurring unexpected monthly costs. For more details, see the [Azure SQL Database free offer documentation](https://learn.microsoft.com/azure/azure-sql/database/free-offer?view=azuresql).
40+
41+
## Recommended action
42+
43+
If you want to use a different SKU for your Azure SQL database deployment, use the new `WithSku` method to specify the desired SKU. For example:
44+
45+
```csharp
46+
var database = resourceBuilder
47+
.AddDatabase("MyDatabase")
48+
.WithSku("GP_S_Gen5_4");
49+
```
50+
51+
Review your existing deployments to ensure they align with the new default behavior.
52+
53+
## Affected APIs
54+
55+
- <xref:Aspire.Hosting.Azure.AzureSqlDatabaseResource>: Updated to use the free offer as the default deployment option.
56+
- <xref:Aspire.Hosting.AzureSqlExtensions.AddDatabase*>: Updated to use the free offer as the default deployment option.
57+
- `public static IResourceBuilder<AzureSqlDatabaseResource> WithSku`: Added to allow specifying the desired SKU.

docs/compatibility/9.3/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,4 @@ If you're migrating an app to .NET Aspire 9.3, the breaking changes listed here
1919
| Title | Type of change | Introduced version |
2020
|--|--|--|
2121
| [With health checks changes in .NET Aspire 9.3](with-health-checks-changes.md) | Binary and source incompatible | 9.3 |
22+
| [Change the default SKU used for creating a new Azure SQL database](azure-sql-server-default-sku-changes.md) | Behavioral change | 9.3 |

docs/compatibility/toc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ items:
1515
items:
1616
- name: With HTTP/S health checks changes
1717
href: 9.3/with-health-checks-changes.md
18+
- name: Azure SQL Server default SKU changes
19+
href: 9.3/azure-sql-server-default-sku-changes.md
1820
- name: .NET Aspire 9.2
1921
expanded: false
2022
items:

0 commit comments

Comments
 (0)