hackney 2.0.0 has been released! This is the first stable release of the 2.x series.
hackney is an HTTP client for Erlang. Version 2.0 is a major rewrite where each connection runs in its own gen_statem process.
Key Features
- HTTP/2 support - Automatic protocol negotiation via ALPN, multiplexing, header compression
- HTTP/3 support - Experimental QUIC/HTTP3 via lsquic (opt-in)
- Process-per-connection - Clean isolation, automatic cleanup on crashes
- Redesigned connection pool - Per-host limits, TCP-only pooling, connection prewarm
- Automatic decompression - Transparent gzip/deflate with {auto_decompress, true}
New in 2.0.0 (since beta.1)
- HTTP 1xx informational responses (#631)
- HTTPS proxy support (#795)
- Proxy authentication callback (#799)
- hackney:peercert/1 to get SSL peer certificate (#599)
- stream_to process is now set as connection owner for async requests (#646)
- Many bug fixes (see changelog)
Requirements
Erlang/OTP 27+
Links
- Hex: hackney | Hex
- GitHub: GitHub - benoitc/hackney: simple HTTP client in Erlang
- Documentation: Overview — hackney v2.0.0
- Changelog: Changelog — hackney v2.0.0
- Migration Guide: https://hexdocs.pm/hackney/2.0.0/migration-guide.html
Feedback welcome!