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

Support for Configurable Timeout for Downstream Connections in HTTP/1.1 #447

Open
ermakov-oleg opened this issue Oct 29, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@ermakov-oleg
Copy link
Contributor

What is the problem your feature solves, or the need it fulfills?

I have several applications that, for various reasons, may open numerous connections and fail to close them properly. As a result, memory usage gradually increases in both the applications and in the Pingora-based proxy due to these open connections. While the main issue originates in the applications, it would be helpful to have protective measures at the proxy level to prevent excessive memory consumption caused by such open connections.

Describe the solution you’d like

It would be helpful to have a downstream setting that configures the keepalive status for connections, so as to limit the time that a connection remains active.

Additional context

Currently, each time a downstream connection is reused, a new ServerSession is created via ServerSession::new_http1, where keepalive_timeout is set to KeepaliveStatus:Off. Then, in HttpSession::read_request in pingora-core/src/protocols/http/v1/server.rs, there is an indefinite wait for data from the socket.

@eaufavor eaufavor added the enhancement New feature or request label Oct 29, 2024
@andrewhavck andrewhavck self-assigned this Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants