mirror of
https://github.com/jambonz/jambonz-api-server.git
synced 2026-10-10 05:14:13 +00:00
The pcap route awaited homer with no timeout and no tie to the client connection, then used stream.pipe(res). If the client gave up (nginx 499) before homer answered, the homer response body was piped into a closed response, pipe() detached without destroying it, and the unread body kept its socket and buffers referenced by the global undici pool forever. With homer slow, this leaked roughly one socket per abandoned request: ~1,300 open fds and +200 MB RSS per api-server worker within four hours. - abort the homer auth and pcap fetches when the response closes or after 30s - use stream.pipeline() so the homer stream is destroyed if the client leaves Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>