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
It suggests that you should use body = Buffer.concat([body, data]); for every chunk received. This causes performance issues for large requests, since the Buffer.concat unnecessarily creates a new copy of the Buffer on every chunk.
This section of the README: https://github.com/nodejitsu/node-http-proxy#modify-response
It suggests that you should use
body = Buffer.concat([body, data]);
for every chunk received. This causes performance issues for large requests, since theBuffer.concat
unnecessarily creates a new copy of the Buffer on every chunk.The NodeJS docs suggest a different approach: pushing each chunk to a mutable array, with only one
Buffer.concat
in the "end" event: https://nodejs.org/en/docs/guides/anatomy-of-an-http-transaction/#request-bodyHappy to submit a PR
The text was updated successfully, but these errors were encountered: