Skip to content

Commit 3e59cf9

Browse files
Copilotgewarren
andcommitted
Add HTTP3 breaking change documentation for .NET 10 Preview 6
Co-authored-by: gewarren <[email protected]>
1 parent 1d53284 commit 3e59cf9

File tree

3 files changed

+58
-0
lines changed

3 files changed

+58
-0
lines changed

docs/core/compatibility/10.0.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ If you're migrating an app to .NET 10, the breaking changes listed here might af
6868

6969
| Title | Type of change | Introduced version |
7070
|-------|-------------------|--------------------|
71+
| [HTTP3 support in System.Net.Http disabled by default with PublishTrimmed](networking/10.0/http3-disabled-with-publishtrimmed.md) | Source incompatible | Preview 6 |
7172
| [HttpClient/SslStream default certificate revocation check mode changed to Online](networking/10.0/ssl-certificate-revocation-check-default.md) | Behavioral change | Preview 6 |
7273
| [Streaming HTTP responses enabled by default in browser HTTP clients](networking/10.0/default-http-streaming.md) | Behavioral change | Preview 3 |
7374

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
---
2+
title: "Breaking change - HTTP3 support in System.Net.Http disabled by default with PublishTrimmed"
3+
description: "Learn about the breaking change in .NET 10 where HTTP3 support is disabled by default when PublishTrimmed or PublishAot is set to true."
4+
ms.date: 1/20/2025
5+
ai-usage: ai-assisted
6+
ms.custom: https://github.com/dotnet/docs/issues/47443
7+
---
8+
9+
# HTTP3 support in System.Net.Http disabled by default with PublishTrimmed
10+
11+
Setting `PublishTrimmed` or `PublishAot` to `true` in the project disables HTTP3 support in System.Net.Http by default.
12+
13+
## Version introduced
14+
15+
.NET 10 Preview 6
16+
17+
## Previous behavior
18+
19+
Previously, HTTP3 support was allowed, but might not have actually worked by default in environments where the msquic native library is not available. This resulted in HTTP3 not actually working while the app carried all the code related to it.
20+
21+
## New behavior
22+
23+
Starting in .NET 10, HTTP3 is disabled and the code for it is not included when `PublishTrimmed` or `PublishAot` is set to `true`.
24+
25+
## Type of breaking change
26+
27+
This change can affect [source compatibility](../../categories.md#source-compatibility).
28+
29+
## Reason for change
30+
31+
Since making HTTP3 work requires extra gestures and often doesn't work by default, the runtime no longer carries the code for it in trimmed or AOT-compiled applications to reduce application size and complexity.
32+
33+
## Recommended action
34+
35+
To enable HTTP3 support in applications that use `PublishTrimmed` or `PublishAot`, set the `<Http3Support>` property to `true` in your project file:
36+
37+
```xml
38+
<PropertyGroup>
39+
<PublishTrimmed>true</PublishTrimmed>
40+
<Http3Support>true</Http3Support>
41+
</PropertyGroup>
42+
```
43+
44+
Or for AOT scenarios:
45+
46+
```xml
47+
<PropertyGroup>
48+
<PublishAot>true</PublishAot>
49+
<Http3Support>true</Http3Support>
50+
</PropertyGroup>
51+
```
52+
53+
## Affected APIs
54+
55+
None.

docs/core/compatibility/toc.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ items:
6262
href: interop/10.0/search-assembly-directory.md
6363
- name: Networking
6464
items:
65+
- name: HTTP3 support in System.Net.Http disabled by default with PublishTrimmed
66+
href: networking/10.0/http3-disabled-with-publishtrimmed.md
6567
- name: HttpClient/SslStream default certificate revocation check mode changed to Online
6668
href: networking/10.0/ssl-certificate-revocation-check-default.md
6769
- name: Streaming HTTP responses enabled by default in browser HTTP clients

0 commit comments

Comments
 (0)