0.5.0 - 2025-05-09
🚀 Features
- Add tweak_new_upstream_tcp_connection hook to invoke logic on new upstream TCP sockets prior to connection
- Add ability to configure max retries for upstream proxy failures
- Allow tcp user timeout to be configurable
- Add peer address to downstream handshake error logs
- Allow proxy to set stream level downstream read timeout
- Improve support for sending custom response headers and bodies for error messages
- Allow configuring multiple listener tasks per endpoint
- Add get_stale and get_stale_while_update for memory-cache
🐛 Bug Fixes
- Fix deadloop if proxy_handle_upstream exits earlier than proxy_handle_downstream
- Check on h2 stream end if error occurred for forwarding HTTP tasks
- Check for content-length underflow on end of stream h2 header
- Correctly send empty h2 data frames prior to capacity polling
- Signal that the response is done when body write finishes to avoid h1 downstream/h2 upstream errors
- Ignore h2 pipe error when finishing an H2 upstream
- Add finish_request_body() for HTTP healthchecks so that H2 healthchecks succeed
- Fix Windows compile errors by updating
impl<T> UniqueID
to use correct return type - Fixed compilation errors on Windows
- Poll for H2 capacity before sending H2 body to propagate backpressure
- Fix for write_error_response for http2 downstreams to set EOS
- Always drain v1 request body before session reuse
- Fixes HTTP1 client reads to properly timeout on initial read
- Fixes issue where if TLS client never sends any bytes, hangs forever
Everything Else
- Add builder api for pingora listeners
- Better handling for h1 requests that contain both transfer-encoding and content-length
- Allow setting raw path in request to support non-UTF8 use cases
- Allow reusing session on errors prior to proxy upstream
- Avoid allocating large buffer in the accept() loop
- Ensure HTTP/1.1 when forcing chunked encoding
- Reject if the HTTP header contains duplicated Content-Length values
- proxy_upstream_filter tries to reuse downstream by default
- Allow building server that avoids std::process::exit during shutdown
- Update Sentry crate to 0.36
- Update the bounds on
MemoryCache
methods to accept broader key types - Flush already received data if upstream write errors
- Allow modules to receive HttpTask::Done, flush response compression on receiving Done task
- API signature changes as part of experimental proxy cache support
- Note MSRV was effectively bumped to 1.82 from 1.72 due to a dependency update, though older compilers may still be able to build by pinning dependencies, e.g.
cargo update -p backtrace --precise 0.3.74
.