What Next After Multiplexing?
You now know the core pattern. These paths take it into production systems.
Advanced lessons to add next
- TLS and ALPN: how a TLS handshake negotiates HTTP/2 with ALPN, then HTTP/2 frames share the encrypted byte stream.
- Observability: how to debug interleaved frames with correlation IDs, per-channel latency, frame logs, and traces.
- Backpressure in practice: windows, high-water marks, slow consumers, and memory safety.
- QUIC and HTTP/3: streams over UDP, packet loss isolation, and why this changes head-of-line blocking.
Primary sources to read
| Topic | Source | Why |
|---|---|---|
| HTTP/2 | RFC 9113 | Streams, frames, flow control. |
| TLS ALPN | RFC 7301 | Negotiating protocols inside TLS. |
| QUIC | RFC 9000 | Multiplexed streams with packet-loss isolation. |
| WebSocket API | MDN WebSockets | Practical browser transport. |
| Event loop | MDN event loop | Callbacks, tasks, and microtasks. |
Project upgrades
- Add a
messageIdfield and display complete vs incomplete messages. - Add a
typingchannel with priority above file chunks. - Add max in-flight frames per channel to model backpressure.
- Add frame logging with
traceId,channel,sequence, and latency. - Replace the teaching WebSocket server with a production library, then compare what the library handles for you.
Carry this rule forward
Every multiplexed system needs four answers: how pieces are labeled, how order is rebuilt, how fairness is enforced, and how you debug one channel without losing sight of the shared road.