With enableJsonResponse: true on a stateful transport, send() resolves the pending Response via resolveJson but never runs the mapping's cleanup, so every completed POST leaks one _streamMapping entry until close(). Conversely, cleanup only deletes the entry without settling the promise, so close() during an in-flight JSON-mode POST leaves the HTTP request hanging.
Pre-existing on both main and v1.x. Split out from the review discussion on #2547.
With
enableJsonResponse: trueon a stateful transport,send()resolves the pending Response viaresolveJsonbut never runs the mapping'scleanup, so every completed POST leaks one_streamMappingentry untilclose(). Conversely,cleanuponly deletes the entry without settling the promise, soclose()during an in-flight JSON-mode POST leaves the HTTP request hanging.Pre-existing on both main and v1.x. Split out from the review discussion on #2547.