Head-of-line blocking can occur in
reliable byte streams: if packets are reordered or
lost and need to be retransmitted (and thus arrive out-of-order), data from sequentially later parts of the stream may be received before sequentially earlier parts of the stream; however, the later data cannot typically be used until the earlier data has been received, incurring
network latency. If multiple independent higher-level messages are
encapsulated and
multiplexed onto a single reliable byte stream, then head-of-line blocking can cause processing of a fully-received message that was sent later to wait for delivery of a message that was sent earlier. This affects, for example,
HTTP/2, which
frames multiple request–response pairs onto a single stream;
HTTP/3, which has an
application-layer framing design and uses
datagram rather than stream transport, avoids this problem. The latency degradation from head-of-line blocking depends on the underlying packet loss rate and
round-trip time, with higher losses producing worse latency. Without changing the stream abstraction, reducing packet loss can reduce the harm from head-of-line blocking; an alternative is to implement the reliable byte stream using
forward error correction to send redundant data so that a certain amount of loss can be tolerated without incurring retransmissions. ==See also==