Class SteamSharedHttpClient
The one HttpClient every Steam request goes out through, never one per caller, so the connections to the partner site are pooled across the partner client, the sign-in clients and the icon downloads.
Inherited Members
Namespace: Serenity.Steam.Infrastructure
Assembly: Serenity.Steam.Infrastructure.dll
Syntax
public static class SteamSharedHttpClient
Remarks
Follows HttpStructuredStore's discipline: one shared, static client, never one per instance.
Methods
SendAsync(HttpRequestMessage, CancellationToken)
Sends request and answers once the whole response has been read.
Declaration
public static Task<HttpResponseMessage> SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| HttpRequestMessage | request | |
| CancellationToken | cancellationToken |
Returns
| Type | Description |
|---|---|
| Task<HttpResponseMessage> |
SendHeadersFirstAsync(HttpRequestMessage, CancellationToken)
Answers when the headers arrive, so the reader decides how much of the body to take (icon downloads).
Declaration
public static Task<HttpResponseMessage> SendHeadersFirstAsync(HttpRequestMessage request, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| HttpRequestMessage | request | |
| CancellationToken | cancellationToken |
Returns
| Type | Description |
|---|---|
| Task<HttpResponseMessage> |