Skip to main content

Module loss_class_sensor

Module loss_class_sensor 

Source
Expand description

Loss-class sensor: congestion-vs-wireless loss differentiation.

A lost shard means two very different things. A congestion drop says the path is overfull: raise parity broadly and ease off the gas. A wireless drop is a random radio hit on an otherwise-fine path: recover it locally with FEC / interleaving and do NOT back off. Treating one as the other is the classic mistake - over-driving a congested path, or needlessly throttling a clean one - so the controller wants to know which it is.

This sensor is a hybrid of two end-to-end loss-differentiation algorithms from Cen, Cosman & Voelker, “End-to-end differentiation of congestion and wireless losses” (IEEE/ACM Trans. Networking 11(5), 2003):

  • mBiaz (inter-arrival). T_min is the minimum packet inter-arrival seen. The paper’s wireless window for a gap of n is [(n+1) * T_min, (n+1.25) * T_min) - the 1.25 upper factor is the modified-Biaz tuning (Fig. 2), tightening the original Biaz [(n+1) * T_min, (n+2) * T_min) to cut congestion misclassification. The bridge ships a block as one GSO burst, so its shards arrive back-to-back and a SUB-window spacing is a batched arrival, not evidence of loss type. So here Biaz votes congestion only when the spacing is at or above the window (a genuine queuing delay); in-window and burst spacing are left to Spike.
  • Spike (relative one-way trip time). With rtt_min / rtt_max the min / max ROTT seen, the path is in a congestion spike when its ROTT rises above rtt_min + alpha * (rtt_max - rtt_min) and leaves it when it falls below rtt_min + beta * (rtt_max - rtt_min), with alpha = 1/2, beta = 1/3 (the paper’s values; the hysteresis keeps the state from flapping). A loss inside the spike is congestion; outside it is wireless. The ROTT is receiver-minus-sender timestamps; a constant clock offset cancels in the min / max range, exact on same-machine and low-skew links.

The hybrid calls a loss congestion when EITHER signal flags it - Biaz sees queuing delay or the path is in a Spike - and wireless only when neither does. Congestion is the costlier miss - the paper notes a congestion loss mistaken for wireless “will not be reduced when the network is congested” - so the tie breaks to congestion.

The sensor holds no clock and does no I/O: the caller supplies the inter-arrival and ROTT (microseconds), so it is deterministic and exhaustively testable with synthetic traces.

Structs§

LossClassSensor
Stateful loss differentiator. observe_interarrival / observe_owd feed it the running timing; classify runs the hybrid on a detected loss.

Enums§

LossClass
One classified loss event.