Skip to content
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

Consider setting a finite ConnectTimeout by default #1678

Closed
MihaZupan opened this issue Apr 28, 2022 · 0 comments · Fixed by #1991
Closed

Consider setting a finite ConnectTimeout by default #1678

MihaZupan opened this issue Apr 28, 2022 · 0 comments · Fixed by #1991
Assignees

Comments

@MihaZupan
Copy link
Member

MihaZupan commented Apr 28, 2022

Starting with 6.0, the consequences of a connection attempt that takes a long time to fail, or somehow becomes stuck are much higher than before (memory leaks, more failed requests ...).

In .NET 7, we made a change in the connection pool where we will now cancel a connection attempt 5 seconds after the request that initiated it completes (or is canceled).

The main mitigation for this in 6.0 is to set SocketsHttpHandler.ConnectTimeout to a finite value. We should consider setting such a default in YARP.
My preference would be that we make the change regardless of target framework (also change it for 7.0).

See #1833 (comment) for more context on this change.

@adityamandaleeka adityamandaleeka added this to the YARP 2.0.0 milestone May 19, 2022
@samsp-msft samsp-msft moved this to 📋 Backlog in YARP 2.x Jun 9, 2022
@karelz karelz moved this from 📋 Backlog to 🔖 Ready in YARP 2.x Jun 16, 2022
@MihaZupan MihaZupan self-assigned this Jan 6, 2023
@samsp-msft samsp-msft moved this from 🔖 Ready to 📋 Backlog in YARP 2.x Jan 9, 2023
@karelz karelz modified the milestones: YARP 2.0.0, Backlog Jan 9, 2023
@MihaZupan MihaZupan modified the milestones: Backlog, YARP 2.0.0 Jan 11, 2023
@MihaZupan MihaZupan removed this from YARP 2.x Jan 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment