go-libp2p
go-libp2p copied to clipboard
quic: rethink connected / disconnected
trafficstars
We should rethink how we treat QUIC connections. Our current connection model assumes a clear separation between the two states "Connected" and "Disconnected".
QUIC has two interesting properties that dilute this distinction:
- It's really cheap to keep a QUIC connection alive. The memory overhead is quite small (and has gotten even smaller with recent quic-go releases). We can also reduce the keep-alive frequency to further bring down the computational cost of a QUIC connection.
- QUIC allows 0-RTT. For the application it doesn't matter that much if we still have a live QUIC connection or if we can just 0-RTT a new connection (at least for replay-safe requests).