x
Size: a a a
A
SA
{
"Depth": 1,
"ClassName": "System.Net.Sockets.SocketException",
"Message": "Resource temporarily unavailable",
"Source": "System.Net.Sockets",
"StackTraceString": " at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)\n at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)\n at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|283_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)\n at System.Net.Http.HttpConnectionPool.DefaultConnectAsync(SocketsHttpConnectionContext context, CancellationToken cancellationToken)\n at System.Net.Http.ConnectHelper.ConnectAsync(Func`3 callback, DnsEndPoint endPoint, HttpRequestMessage requestMessage, CancellationToken cancellationToken)",
"RemoteStackTraceString": null,
"RemoteStackIndex": 0,
"HResult": -2147467259,
"HelpURL": null
}
HttpClient регистрируется вот так:services.AddHttpClient<IDownloader, Downloader>()
.ConfigurePrimaryHttpMessageHandler(provider =>
{
var config = provider
.GetRequiredService<IConfiguration>()
.GetSection("FileStorageSettings");
var domain = config.GetValue<string>("Domain");
var username = config.GetValue<string>("Username");
var password = config.GetValue<string>("Password");
return new HttpClientHandler
{
Credentials = new NetworkCredential(username, password, domain)
};
});;
SA
IC
SA
IL
SA
IL
IL
DB
DB
DB
IC
AT