mirror of
https://github.com/nodejs/node.git
synced 2026-10-14 10:26:26 -04:00
http: add comment about outputSize in res/server
PR-URL: https://github.com/nodejs/node/pull/3128
This commit is contained in:
1 parent
820735d967
commit
59cb053394
2 files changed
+11
No files matched your search
@@ -265,6 +265,10 @@ function connectionListener(socket) {
|
||||
var outgoingData = 0;
|
||||
|
||||
function updateOutgoingData(delta) {
|
||||
// `outgoingData` is an approximate amount of bytes queued through all
|
||||
// inactive responses. If more data than the high watermark is queued - we
|
||||
// need to pause TCP socket/HTTP parser, and wait until the data will be
|
||||
// sent to the client.
|
||||
outgoingData += delta;
|
||||
if (socket._paused && outgoingData < socket._writableState.highWaterMark)
|
||||
return socketOnDrain();
|
||||
|
||||
Reference in new issue
Block a user