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

Is it possible make oatpp::network::tcp::client::ConnectionProvider support bind client IP? #929

Open
liaoya opened this issue Apr 8, 2024 · 0 comments

Comments

@liaoya
Copy link

liaoya commented Apr 8, 2024

Now I have written a WebSocket performance testing tool based on the client code of websocket-benchmark. In that benchmark, the server can listen on a lot of port so the client setup millions of connections. But our production server will only expose one port.

I look at the code. ConnectCoroutine::act() of oatpp/src/oatpp/network/tcp/client/ConnectionProvider.cpp is responsible for create TCP socket. I think if we can bind IP after create socket and before connect. Can we change oatpp/network/Address.hpp and make it contain the client IP. Then we can use it in ConnectCoroutine::act().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant