fn check_ranges(message: &ControlMessage) -> Result<(), CodecError>Expand description
Refuse a FETCH whose range ends before it starts.
Section 10.12.3: “Fetch specifies an inclusive range of Objects starting at Start Location and ending at End Location. End Location MUST specify the same or a larger Location than Start Location for Standalone and Absolute Joining Fetches.” A Joining Fetch names no explicit range - it is computed from the subscription it joins - so only a standalone range is checked here.
SUBSCRIBE is not checked here, and needs no check: this draft’s AbsoluteRange filter carries an End Group Delta measured from the start location rather than an absolute End Group, so an end before the start has no encoding.
Applied on both sides. A range that ends before it starts selects nothing, and the peer’s only recourse is an error response or a session close, so writing one is not a way to ask for anything.