#reading-list **URL:** https://brooker.co.za/blog/2024/05/09/nagle.html ## Summary - TCP has two conflicting algorithms built into most protocol implementations: - Nagle’s algorithm, which prevents sending data until outstanding packets are ACKed, - Delayed Acks, which delays sending ACKs to instead ACK multiple packets at once. - The interaction between these two can lead to unpredictable spikes in latency. - The solution is to open your sockets with `TCP_NODELAY` which turns off Nagle. - Upshot: TCP was designed at a time where small (single-byte) packets were common, e.g. with Telnet. That is no longer a predominant use-case in networking, so it’s important to reassess the assumptions and potentially change the defaults on server hardware.