-
Notifications
You must be signed in to change notification settings - Fork 1.6k
HttpClient: remove redundant and outdated runtime config switch information #5028
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Docs Build status updates of commit 3103a27: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating this!
Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com>
Co-authored-by: Genevieve Warren <24882762+gewarren@users.noreply.github.com>
xml/System.Net.Http/HttpClient.xml
Outdated
``` | ||
|
||
- By defining an environment variable named `DOTNET_SYSTEM_NET_HTTP_USESOCKETSHTTPHANDLER` and setting it to either `false` or 0. | ||
Certain aspects of <xref:System.Net.Http.HttpClient>'s behavior are customizable through [Run-time configuration options](https://docs.microsoft.com/en-us/dotnet/core/run-time-config/networking). However, the behavior of these switches differs through .NET versions. For example, in .NET Core 2.1 - 3.1, you can configure whether <xref:System.Net.Http.SocketsHttpHandler> is used by default, but that option is no longer available starting in .NET 5.0. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gewarren is this the right way to reference conceptual docs?
[Run-time configuration options](https://docs.microsoft.com/en-us/dotnet/core/run-time-config/networking)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it should be [Run-time configuration options](/dotnet/core/run-time-config/networking)
. Thanks for checking.
Docs Build status updates of commit c85d665: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
Docs Build status updates of commit 0c2706b: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
Docs Build status updates of commit de79bac: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
``` | ||
|
||
- By defining an environment variable named `DOTNET_SYSTEM_NET_HTTP_USESOCKETSHTTPHANDLER` and setting it to either `false` or 0. | ||
Certain aspects of <xref:System.Net.Http.HttpClient>'s behavior are customizable through [Run-time configuration options](/dotnet/core/run-time-config/networking). However, the behavior of these switches differs through .NET versions. For example, in .NET Core 2.1 - 3.1, you can configure whether <xref:System.Net.Http.SocketsHttpHandler> is used by default, but that option is no longer available starting in .NET 5.0. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the UseSocketsHttpHandler
switch be also marked as available only till .NET Core 3.1 in the referenced docs https://docs.microsoft.com/en-us/dotnet/core/run-time-config/networking?
And would it make sense to mention that using WinHttpHandler
is still possible via OOB nuget package (manually setting it to HttpClient
ctor)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the
UseSocketsHttpHandler
switch be also marked as available only till .NET Core 3.1 in the referenced docs https://docs.microsoft.com/en-us/dotnet/core/run-time-config/networking?
I'm not a big fan of documenting the same thing in redundant ways, so in this PR I'm replacing the detailed docs of UseSocketsHttpHandler
in HttpClient
's remarks section by a reference to the runtime switches page, which is being updated in dotnet/docs#21197. Does this answer your question, or did you mean something different?
And would it make sense to mention that using
WinHttpHandler
is still possible via OOB nuget package (manually setting it toHttpClient
ctor)?
Addressed in e2285e6
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, that's perfect! I wasn't aware of the other PR and the existing note. Thank you!
Docs Build status updates of commit e2285e6: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
Removes redundant and outdated (!) information about runtime configuration options for
HttpClient
, referencing the options docs page instead.Related PR updating the options docs: dotnet/docs#21197