Comment by rsaxvc
3 years ago
It matters less often - it can still matter at the end of each write buffer. Larger write-buffers remove a lot of chances for this to happen.
If the application can buffer the entire file or use sendfile, probably best to disable Nagle's algorithm so the last packet goes out immediately. Nginx does this.
Another option is turning off Nagle's algorithm at the end of each transfer, and on at the start of the next, but this causes extra syscalls.
No comments yet
Contribute on Hacker News ↗