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
I thoroughly searched the existing issues in the Restify repository to check if this problem had already been reported. However, I could not find any issue that matches the exact behavior I am experiencing. While there are some discussions around bodyParser, none of them address the specific problem where the request connection is prematurely marked as closed when handling POST requests
Restify Version
v5.0.0 (also tested on latest version as well)
Node.js Version
v22.11.0 ( also tested with 16.19.0)
OS
Ubuntu 20.04 (WSL2), Windows 11
Expected behaviour
Middleware should proceed sequentially to the next handler when next() is called.
Actual behaviour
When using restify.plugins.bodyParser(), the request connection state is unexpectedly marked as closed. If a middleware function performs an async operation (e.g., setTimeout, async/await), calling next() after the delay results in a RequestCloseError.
Bug Report
I thoroughly searched the existing issues in the Restify repository to check if this problem had already been reported. However, I could not find any issue that matches the exact behavior I am experiencing. While there are some discussions around bodyParser, none of them address the specific problem where the request connection is prematurely marked as closed when handling POST requests
Restify Version
v5.0.0 (also tested on latest version as well)
Node.js Version
v22.11.0 ( also tested with 16.19.0)
OS
Ubuntu 20.04 (WSL2), Windows 11
Expected behaviour
Middleware should proceed sequentially to the next handler when next() is called.
Actual behaviour
When using restify.plugins.bodyParser(), the request connection state is unexpectedly marked as closed. If a middleware function performs an async operation (e.g., setTimeout, async/await), calling next() after the delay results in a RequestCloseError.
This issue only occurs for POST requests.
Code
`
`
What's Happening
Can anyone please help me with the issue?
The text was updated successfully, but these errors were encountered: