-
Notifications
You must be signed in to change notification settings - Fork 10k
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
Unexpected exception: System.Net.Quic.QuicException(ConnectionIdle) - The connection timed out from inactivity. #49780
Comments
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process. |
@pavelsavara can you try this out with the latest RTM build and see if it's still a problem? Thanks! |
Repro: Update Program.cs in Http3SampleApp: // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
using System.Net;
using System.Net.Security;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using Microsoft.AspNetCore.Connections;
using Microsoft.AspNetCore.Internal;
using Microsoft.AspNetCore.Server.Kestrel.Core;
using Microsoft.AspNetCore.Server.Kestrel.Https;
using Microsoft.Extensions.Logging.Abstractions;
namespace Http3SampleApp;
public class Program
{
public static void Main(string[] args)
{
Environment.SetEnvironmentVariable("ASPNETCORE_HOSTINGSTARTUPASSEMBLIES", null);
var hostBuilder = new HostBuilder()
.ConfigureLogging((_, factory) =>
{
factory.SetMinimumLevel(LogLevel.Information);
factory.AddSimpleConsole(o => o.TimestampFormat = "[HH:mm:ss.fff] ");
})
.ConfigureWebHost(webHost =>
{
var cert = CertificateLoader.LoadFromStoreCert("localhost", StoreName.My.ToString(), StoreLocation.CurrentUser, false);
webHost.UseKestrel()
.ConfigureKestrel((context, options) =>
{
options.Limits.KeepAliveTimeout = TimeSpan.FromSeconds(500);
options.ListenLocalhost(5001, listenOptions =>
{
listenOptions.Protocols = HttpProtocols.Http3;
listenOptions.UseHttps();
});
})
.UseStartup<Startup>();
});
var host = hostBuilder.Build();
// Listener needs to be configured before host (and HTTP/3 endpoints) start up.
using var httpEventSource = new HttpEventSourceListener(NullLoggerFactory.Instance);// host.Services.GetRequiredService<ILoggerFactory>());
host.Run();
}
} Client app: var client = new HttpClient()
{
BaseAddress = new Uri("https://localhost:5001"),
DefaultRequestVersion = new Version(3, 0),
DefaultVersionPolicy = HttpVersionPolicy.RequestVersionExact,
};
try
{
Console.WriteLine("Requesting /");
var response = await client.GetAsync("/");
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStringAsync();
Console.WriteLine(data);
}
catch (HttpRequestException e)
{
Console.WriteLine($"Request error: {e.Message}");
}
Thread.Sleep(TimeSpan.FromSeconds(30)); // ConnectionIdle with Sleep, ConnectionTimeout without
client.Dispose(); |
As noted here, even though we set the server's idle timeout to be infinite, the client has its own timeout. As a result, that exception is less impossible than we seem to have expected. The fix for the assert is probably to add a catch block like this for However, we should also think through the scenario and ensure that the |
Is there an existing issue for this?
Describe the bug
edit and continue session failed
Expected Behavior
start the app again after browser reload
Steps To Reproduce
src\Components\WebAssembly\Samples\HostedBlazorWebassemblyApp\Server
dotnet watch -c Debug
Exceptions (if any)
Server side
.NET Version
8.0.100-rc.1.23381.2
Anything else?
No response
The text was updated successfully, but these errors were encountered: