Summary

  • A QUIC stream direction is an ordered byte sequence; STREAM frame boundaries do not survive as application-message boundaries.
  • FIN and RESET_STREAM communicate an immutable Final Size that reconciles consumed flow-control credit.
  • Final Size is not proof that bytes were read, parsed, committed, compensated, or turned into a business result.

A completion dashboard can be technically precise and operationally wrong at the same time. It may observe a known final size and label a request complete, while the transport fact only says where the byte sequence ends. The distinction matters because one direction can end cleanly with a STREAM frame carrying FIN or abruptly with RESET_STREAM. Both can establish the same kind of accounting boundary, but neither alone answers the application’s larger questions.

QUIC presents each stream direction as an ordered sequence of bytes. The boundaries of individual STREAM frames are not preserved through transmission, retransmission, or delivery. An application therefore cannot use a frame boundary as a message delimiter. Its own protocol must define message framing and determine whether a complete message has arrived.

For a STREAM frame carrying FIN, the final size is the frame offset plus its data length. RESET_STREAM carries an explicit Final Size field. The value is one greater than the largest byte offset sent, or zero when no bytes were sent. It is not a count of successful business operations. It is the stream direction’s consumed flow-control credit, allowing both endpoints to reconcile connection-level accounting. The sum of final sizes across streams counts toward connection flow control, including streams that terminate.

Once known, Final Size cannot change. A later declaration with a different value, or data at or beyond the established boundary, can lead to FINAL_SIZE_ERROR. That invariant protects accounting, but it does not upgrade accounting into delivery evidence. State may need to be retained after closure so a peer’s later frames can still be checked against the known boundary.

The receive path has several distinct states. Learning a final size is not the same as receiving every byte below it. Receiving all bytes is not the same as delivering them to the application. Delivery is not the same as an application read; an application read is not successful parsing, durable commit, rollback, compensation, or business completion. A reset makes the distinction more visible: RESET_STREAM can interrupt delivery and allow unread data to be discarded, yet it does not prove that nothing arrived. All data might already have been buffered, and the reset indication itself can be suppressed.

Packet acknowledgment belongs to a lower evidence layer. Processing a STREAM frame requires enqueueing its bytes for the application, but an ACK does not prove that the application read or acted on them. Likewise, a known Final Size says nothing by itself about the opposite stream direction or the connection as a whole.

A useful evidence ledger records stream ID and direction; FIN or RESET_STREAM; the reset application error code when present; the source, numeric value, and immutability of Final Size; highest observed offset and contiguous-byte coverage; whether every byte entered the receiver; whether bytes were delivered to or read by the application; application-protocol framing; commit, compensation, rollback, and business outcome; and any FINAL_SIZE_ERROR state retained for detection.

This boundary also keeps adjacent questions separate. TR-046 concerns permission to send before higher offsets are used, not the final accounting total after a direction ends. TR-052 concerns DATAGRAM message boundaries, whereas a QUIC stream is an ordered byte sequence without preserved STREAM-frame boundaries. TR-053 concerns connection-wide closure, not one stream direction. TR-054 concerns STOP_SENDING and cancellation evidence, not the sender’s immutable byte extent. TR-045 limits ACK evidence to packet processing, not application delivery. Those are five separate dimensions, not interchangeable completion signals.