@@ -117,6 +117,10 @@ http.get({
117
117
<!-- YAML
118
118
added: v0.3.4
119
119
changes:
120
+ - version:
121
+ - CHANGEME
122
+ pr-url: https://github.com/nodejs/node/pull/42163/files
123
+ description: Changed the default value of `keepAlive` to `true`.
120
124
- version:
121
125
- v15.6.0
122
126
- v14.17.0
@@ -144,11 +148,11 @@ changes:
144
148
header is always sent when using an agent except when the ` Connection `
145
149
header is explicitly specified or when the ` keepAlive ` and ` maxSockets `
146
150
options are respectively set to ` false ` and ` Infinity ` , in which case
147
- ` Connection: close ` will be used. ** Default:** ` false ` .
151
+ ` Connection: close ` will be used. ** Default:** ` true ` .
148
152
* ` keepAliveMsecs ` {number} When using the ` keepAlive ` option, specifies
149
153
the [ initial delay] [ ]
150
154
for TCP Keep-Alive packets. Ignored when the
151
- ` keepAlive ` option is ` false ` or ` undefined ` . ** Default:** ` 1000 ` .
155
+ ` keepAlive ` option is ` false ` . ** Default:** ` 1000 ` .
152
156
* ` maxSockets ` {number} Maximum number of sockets to allow per host.
153
157
If the same host opens multiple concurrent connections, each request
154
158
will use new socket until the ` maxSockets ` value is reached.
@@ -2838,6 +2842,12 @@ Found'`.
2838
2842
<!-- YAML
2839
2843
added: v0.1.13
2840
2844
changes:
2845
+ - version:
2846
+ - CHANGEME
2847
+ pr-url: https://github.com/nodejs/node/pull/42163/files
2848
+ description: Changed the default value of `noDelay` and `keepAlive`
2849
+ to `true`. Changed the default value of `keepAliveInitialDelay`
2850
+ to `1000`.
2841
2851
- version:
2842
2852
- v13.8.0
2843
2853
- v12.15.0
@@ -2871,14 +2881,14 @@ changes:
2871
2881
** Default:** 16384 (16 KB).
2872
2882
* ` noDelay ` {boolean} If set to ` true ` , it disables the use of Nagle's
2873
2883
algorithm immediately after a new incoming connection is received.
2874
- ** Default:** ` false ` .
2884
+ ** Default:** ` true ` .
2875
2885
* ` keepAlive ` {boolean} If set to ` true ` , it enables keep-alive functionality
2876
2886
on the socket immediately after a new incoming connection is received,
2877
2887
similarly on what is done in \[ ` socket.setKeepAlive([enable][, initialDelay]) ` ] \[ ` socket.setKeepAlive(enable, initialDelay) ` ] .
2878
- ** Default:** ` false ` .
2888
+ ** Default:** ` true ` .
2879
2889
* ` keepAliveInitialDelay ` {number} If set to a positive number, it sets the
2880
2890
initial delay before the first keepalive probe is sent on an idle socket.
2881
- ** Default:** ` 0 ` .
2891
+ ** Default:** ` 1000 ` .
2882
2892
2883
2893
* ` requestListener ` {Function}
2884
2894
0 commit comments