-
Notifications
You must be signed in to change notification settings - Fork 382
bug: iroh-relay's server side doesn't set the TCP socket to no-delay #3974
Description
Describe the bug
Source code evidence
Iroh-relay
-
Client-side configuration:
client/tls.rsL156 and L188 both havetcp_stream.set_nodelay(true) -
Server-side missing:
server/http_server.rsL362 has no call afterlistener.accept()
Relevant Logs
Expected behavior
Iroh
Version: 0.96.0 All of the previous versions exist.
Platform(s)
All
Additional Context / Screenshots / GIFs
My current solution is patching.
res = listener.accept() => match res {
Ok((stream, peer_addr)) => {
debug!("connection opened from {peer_addr}");
stream.set_nodelay(true).ok();
These are my previous test records of specific latency and test results.
The final result, which I have attached to the screenshot, shows that the latency dropped directly from 300-400ms to 140-150ms. This is the result I ultimately hoped for in the discussion forum: 70ms * 2
If possible, I would like to add nagle to the server configuration. Algorithm configuration options control whether the relay service is enabled on Nagle. This is a crucial option for latency-sensitive applications with frequent small packet transmissions.

Metadata
Metadata
Assignees
Labels
Type
Projects
Status