Releases: nodejs/undici
Releases · nodejs/undici
v2.0.5
v2.0.4
v2.0.3
v2.0.2
v2.0.1
v2.0.0
Breaking
Client.dispatch
providesheaders
andtrailers
as an array of values (#337).Client.dispatch
adds aonConnect
handler to handle abort once dispatched on socket.Client.dispatch
expects request body to be handled by caller untilonConnect
has been called.- Removed
signal
option inClient.dispatch
. - Removed
requestTimeout
option innew Client(url, opts)
. ProviderequestTimeout
as an option for each individual request (#383). Client.busy
behavior slightly changed (#366).- Rename
maxKeepAliveTimeout
option innew Client(url, opts)
tokeepAliveMaxTimeout
(#359). requestTimeout
monitors time from request having been sent instead of from when it was queued (#343).- Error
body
on premature close (#336).
Fixes
- Unhandled exception (#372).
- Destroy request body on invalid callback (#382).
- Run
Client.upgrade
&Client.connect
callbacks in async scope. - CONNECT calls onUpgrade multiple times (#348).
- Don't reset socket until pipeline is empty (#334).
- Allow throwing from handler (#335).
Improvements
Upgrade & Connect
- Added new API's,
dispatch
,connect
,upgrade
. - Callbacks with error now also receive a
{ opaque }
object as value. stream(opts, handler, callback)
callback now receive a{ trailers, opaque }
object as value.- Misc refactoring and perf improvements.
- Async scope is no longer propagated across events.
- Added
idleTimeout
option to differentiate timeout of active vs inactive sockets. - Added support for keep-alive response header timeout hint as well as
maxKeepAliveTimeout
,keepAliveTimeoutThreshold
options.
v1.2.6
v1.2.2
v1.2.0
- Improved stream compat.
- Reset connection after requests with body where the method does not expect a payload.
- Validate user provided content-length and transfer-encoding headers.
- Error if content-length header and body length does not match.
- Avoid chunked transfer if request body stream is ended in same tick.
- Added
InformationalError
for'disconnect'
event for when a disconnect was expected. - Refactoring.