You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Release the response entity when the client is gone before the server starts writing it #1774
In 3.0.0-m2, NettyServerCall.sendResponse throws "Connection closed by peer" at its start, before the try/finally that calls Representation.release() on the response entity. handleException then only logs at INFO.
When the response entity wraps a stream from another connection, nothing closes it. Ikanos hits this with streamed binary answers (naftiko/ikanos#1240): the entity is an InputRepresentation over the upstream response body. A client that disconnects while the application waits for the upstream leaves that body open, and the upstream connection stays out of its pool until a timeout.
Release on an error during the write, and on a client leaving mid-stream, already works, since those paths go through the finally.
Expected: the response entity is released whatever the point at which the call fails, including when the peer is gone before the write starts.
Observed with javap -c on org.restlet.engine.netty.NettyServerCall (3.0.0-m2). Related, older and broader: #795.
Activity
Log the release of the response entity of a gone client in changes.md (…
Release the response entity when the client is gone before the write (#…
Log the release of the response entity of a gone client in changes.md (…
jlouvel commentedon Dec 1, 2026
Fixed by #1776, merged into 3.0.