A userspace reliable transmission protocol whose congestion window is governed only by the delivery rate (i.e., bandwidth/throughput) and the data loss rate.
Treat RTP like TCP for behavior common to reliable stream transports. In particular, FIN is a graceful directional close and KILL/RST is an abort; EOF, half-close, and write-after-close behavior should follow the TCP model. When RTP intentionally defines different behavior, follow the RTP rule for that specific behavior and keep the difference inside the RTP implementation.
- an async-free reliable layer
- a piece of pure algorithm
- main entry: [[src/reliable/reliable_layer.rs]]
- send window: [[src/traffic_shaping/recovery/pkt_send_space.rs]]
- recv window: [[src/recv_queue/pkt_recv_space.rs]]
- ACK calculation: [[src/ack/]] (intervals, wire selection, sender interpretation)
- a dead simple codec for packet encoding/decoding
- main entry: [[src/codec.rs]]
- wireshark dissector: [[wireshark/rtp.dissector.lua]]
- an async-based I/O-agnostic transmission layer
- gluing the unreliable layer and the reliable layer together
- main entry: [[src/transmission/transmission_layer.rs]]
- a user-facing I/O-agnostic socket wrapper
- managing opening, closing, timer, async read/write for the transmission layer
- perk: You are allowed to wait until or check if the send buf is empty!
- owning the validated frame-delivery-to-AsyncRead/AsyncWrite adaptation
- main entry: [[src/socket.rs]]
- a user-facing over-UDP implementation
- exposing listening, accepting, and connecting APIs
- main entry: [[src/udp.rs]]
- a user-facing keyed-streams over-single-UDP-connection implementation
- exposing listening, accepting, and connecting APIs
- main entry: [[src/keyed_udp.rs]]
- traffic-shaping policy, organized by concern:
- adjacent observations/configuration: [[src/traffic_shaping/adjacent/]]
- reverse/control traffic: [[src/traffic_shaping/control/]]
- core forward shaping: [[src/traffic_shaping/core/]]
- recovery shaping: [[src/traffic_shaping/recovery/]]
- redundancy shaping: [[src/traffic_shaping/redundancy/]]
Run the test suite:
cargo test- as a high-level socket user: Refer to the [[examples]] directory and the test sections in [[src/udp.rs]] and [[src/keyed_udp.rs]].
- as a low-level reliable layer user: Refer to the test sections in [[src/socket.rs]].