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

set so_reuseaddr for client in reverse proxy mode so uses 1 connection to interface with server. #137

Open
ouvaa opened this issue Mar 21, 2024 · 3 comments
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@ouvaa
Copy link

ouvaa commented Mar 21, 2024

set so_reuseaddr for client in reverse proxy mode so uses 1 connection to interface with server.

the server side will save on fd with 1 connection

@ouvaa
Copy link
Author

ouvaa commented Mar 21, 2024

if there's already an example, pls provide it. thx

@li-jin-gou
Copy link
Member

Isn't this the keep alive feature of HTTP1?

@ouvaa
Copy link
Author

ouvaa commented Mar 23, 2024

@li-jin-gou no, it's running multiple client processes in one port.

https://blog.cloudflare.com/how-to-stop-running-out-of-ephemeral-ports-and-start-to-love-long-lived-connections

can you please provide the code example for using so_reuseaddr as a proxy as the client connecting to backend? will be running multiple processes to tie the client to single port

@li-jin-gou li-jin-gou added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Mar 23, 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 good first issue Good for newcomers help wanted Extra attention is needed
Development

No branches or pull requests

2 participants