v0.55.0
This release contains a number of improvements and fixes, and it updates the supported Go versions to 1.24 and 1.25.
Optimizations
When sending packets on a QUIC connection, RFC 9002 requires us to save the timestamp for every packet sent. In #5344, we implemented a memory-optimized drop-in replacement for time.Time, which reduces the memory required from 24 to 8 bytes, and vastly speeds up timer calculations (which happen very frequently).
New Features
- Basic connection statistics are now exposed via
Conn.ConnectionStats, thanks to @MarcoPolo - On some links, packet reordering can lead to spurious detections of packet loss when using the loss detection logic specified in RFC 9002. #5355 adds logic detect when packet loss is detected spuriously.
Notable Fixes
- http3: don't allow usage of closed
Transport: #5324, thanks to @Glonee - http3: fix race in concurrent
Transport.Roundtripcalls: #5323, thanks to @Glonee - improve and fix connection timer logic: #5339, thanks to @sukunrt for a very comprehensive code review
Behind the Scenes
We have started transitioning tests to make use of the new synctest package that was added in Go 1.25 (and was available as a GOEXPERIMENT in Go 1.24): #5291, #5296, #5298, #5299, #5302, #5304, #5305, #5306, #5317. This is a lot of work, but it makes the test execution both faster and more reliable.
Changelog
- wire: implement parsing and writing of the ACK_FREQUENCY frame by @marten-seemann in #5264
- wire: implement parsing and writing of the IMMEDIATE_ACK frame by @marten-seemann in #5265
- fuzzing: fix timeout in frame parser by @jannis-seemann in #5268
- wire: add support for the min_ack_delay transport parameter by @marten-seemann in #5266
- fix missing log statement for STREAM, DATAGRAM and ACK by @jannis-seemann in #5273
- qlog: add support for ACK_FREQUENCY and IMMEDIATE_ACK frames by @marten-seemann in #5276
- ackhandler: remove unused time from receivedPacketHandler.ReceivedPacket by @marten-seemann in #5277
- quicvarint: extend benchmark to use quicvarint.Reader by @marten-seemann in #5278
- quicvarint: tolerate empty reads of the underlying io.Reader by @bemasc in #5275
- http3: fix documentation for Server.ServeListener by @WeidiDeng in #5282
- expose connection stats via Conn.ConnectionStats by @marten-seemann in #5281
- ackhandler: generalize check for missing packets below threshold by @marten-seemann in #5260
- update to Go 1.25, drop Go 1.23, use go tool for gomock by @marten-seemann in #5283
- replace
interface{}withanyby @marten-seemann in #5290 - use testing.B.Loop in all benchmark tests by @marten-seemann in #5285
- build(deps): bump actions/checkout from 4 to 5 by @dependabot[bot] in #5293
- use synctest to make receive stream tests fully deterministc by @marten-seemann in #5291
- use synctest to make streams map tests fully deterministic by @marten-seemann in #5296
- ci: cache the Go build cache for cross-compilation workflow by @marten-seemann in #5297
- ci: fix cache save and restore logic for cross compile workflow by @marten-seemann in #5300
- restore previously deleted TestStreamsMapConcurrent test by @marten-seemann in #5301
- use synctest to make the send queue tests fully deterministic by @marten-seemann in #5302
- use synctest to make the send stream tests fully deterministic by @marten-seemann in #5298
- ci: use
go mod tidy -diffto check for tidiedgo.modby @marten-seemann in #5303 - use synctest to make the datagram queue tests fully deterministic by @marten-seemann in #5305
- utils: use synctest to make the timer tests fully deterministic by @marten-seemann in #5306
- ackhandler: fix resetting of packet.isPathProbePacket by @marten-seemann in #5310
- ackhandler: use an iterator to process received packet ranges by @marten-seemann in #5309
- ackhandler: use a typed mock for the ECNHandler by @marten-seemann in #5311
- ackhandler: immediately clear ackedPacket slice after processing ACK by @marten-seemann in #5313
- ci: improve cache key generation for the cross compilation job by @marten-seemann in #5315
- ci: fix cache paths in cross compile workflow by @marten-seemann in #5318
- ackhandler: avoid storing packet number in packet struct by @marten-seemann in #5312
- ackhandler: store skipped packet numbers separately by @marten-seemann in #5314
- ackhandler: account for skipped packets in packet threshold calculation by @marten-seemann in #5316
- ackhandler: store the last four skipped packets by @marten-seemann in #5322
- http3: fix data race in Transport by @Glonee in #5323
- qlog: add a benchmark for the ConnectionTracer by @marten-seemann in #5328
- qlog: merge event category and name by @marten-seemann in #5329
- http3: don't allow usage of closed Transport by @Glonee in #5324
- build(deps): bump actions/setup-go from 5 to 6 by @dependabot[bot] in #5330
- fix: return stream frames to pool on error paths by @lidel in #5327
- ackhandler: add a benchmark for sending and acknowledging packets by @marten-seemann in #5333
- implement a memory-optimized time.Time replacement by @marten-seemann in #5334
- add a benchmark test for data transfers by @marten-seemann in #5335
- improve connection timer logic by @marten-seemann in #5339
- use synctest to make the connection tests fully deterministic by @marten-seemann in #5317
- drop initial packets when the handshake is confirmed by @marten-seemann in #5354
- protocol: optimize ConnectionID.String by @marten-seemann in #5351
- fix missing tracing of restored transport parameters by @marten-seemann in #5349
- ackhandler: track lost packets and detect spurious losses by @marten-seemann in #5355
New Contributors
Full Changelog: v0.54.0...v0.55.0