Rich Trott
fb0bd8a584
test: fix flaky test-child-process-pass-fd
...
test-child-process-pass-fd needs to launch many processes
simultaneously. On Fedora 24, this can result in EAGAIN "Resource
temporarily unavailable" errors. When this occurs, simply try to launch
a worker again.
PR-URL: https://github.com/nodejs/node/pull/17598
Fixes: https://github.com/nodejs/node/issues/17589
Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
2018-02-12 19:28:13 -05:00
Will Clark
83fe79c558
doc: correct pbkdf2 salt length recommendation
...
According to the linked document: "The length of the randomly-generated
portion of the salt shall be at least 128 bits." [NIST SP 800-132]
PR-URL: https://github.com/nodejs/node/pull/17524
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-02-12 19:28:13 -05:00
Jamie Davis
b3b245665e
test: add test description to fs.readFile tests
...
PR-URL: https://github.com/nodejs/node/pull/17610
Refs: https://github.com/nodejs/node/pull/17054#discussion_r155406755
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com >
Reviewed-By: Jon Moss <me@jonathanmoss.me >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2018-02-12 19:28:13 -05:00
Jon Moss
cdf4a9c394
module: add builtinModules
...
Provides list of all builtin modules in Node.
Includes modules of all types:
- prefixed (ex: _tls_common)
- deprecated (ex: sys)
- regular (ex: vm)
Backport-PR-URL: https://github.com/nodejs/node/pull/18221
PR-URL: https://github.com/nodejs/node/pull/16386
Refs: https://github.com/nodejs/node/issues/3307
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-02-12 19:28:12 -05:00
Daniel Bevenius
2268d00e38
src: add openssl-system-ca-path configure option
...
The motivation for this commit is that we need to specify system CA
certificates when building node. While we are aware of the environment
variable NODE_EXTRA_CA_CERTS this is not a great solution as we build
an RPM and we also don't want users to be able to unset them.
The suggestion is to add a configure time property like this:
--openssl-system-ca-path=OPENSSL_SYSTEM_CA_PATH
Use the specified path to system CA (PEM format) in
addition to the OpenSSL supplied CA store or compiled-
in Mozilla CA copy.
Usage example:
$ ./configure --openssl-system-ca-path=/etc/pki/tls/certs/ca-bundle.crt
This would add the specified CA certificates in addition to the ones
already being used.
Backport-PR-URL: https://github.com/nodejs/node/pull/18173
PR-URL: https://github.com/nodejs/node/pull/16790
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2018-02-12 19:28:12 -05:00
Fedor Indutny
1390c280bc
http: overridable keep-alive behavior of Agent
...
Introduce two overridable `Agent` methods:
* `keepSocketAlive(socket)`
* `reuseSocket(socket, req)`
These methods can be overridden by particular `Agent` class child to
make keep-alive behavior customizable.
Motivation: destroy persisted sockets after some configurable timeout.
It is very non-trivial to do it with available primitives. Such program
will most likely need to poke with undocumented events and methods of
`Agent`. With introduced API such behavior is easy to implement.
Backport-PR-URL: https://github.com/nodejs/node/pull/18168
PR-URL: https://github.com/nodejs/node/pull/13005
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Brian White <mscdex@mscdex.net >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
2018-02-12 19:28:12 -05:00
Daniel Bevenius
5f7944842a
test: fix truncation of argv
...
Currently argv_[1] and argv_[2] are getting truncated by one character
because of an incorrect addition of one to account for the null
character. I only noticed this when working on #12087 , but that fix
will probably not get included in favor of a JavaScript test so I'm
adding this separate commit for it.
Refs: https://github.com/nodejs/node/pull/12087
Backport-PR-URL: https://github.com/nodejs/node/pull/18113
PR-URL: https://github.com/nodejs/node/pull/12110
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
2018-02-12 19:28:11 -05:00
Timothy Gu
c64a73ba6c
promises: more robust stringification
...
Backport-PR-URL: https://github.com/nodejs/node/pull/17833
PR-URL: https://github.com/nodejs/node/pull/13784
Fixes: https://github.com/nodejs/node/issues/13771
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Rod Vagg <rod@vagg.org >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:11 -05:00
James M Snell
24def19417
url: adding WHATWG URL support
...
Implements WHATWG URL support. Example:
```
var u = new url.URL('http://example.org ');
```
Many, many other commits improving the implementation have been squashed
into this backport PR. They are not listed separately here for brevity.
Backport-PR-URL: https://github.com/nodejs/node/pull/17365
PR-URL: https://github.com/nodejs/node/pull/7448
Reviewed-By: Ilkka Myller <ilkka.myller@nodefield.com >
2018-02-12 19:28:11 -05:00
Timothy Gu
60b10f0896
url: update IDNA handling
...
Remove custom tests for invalid IDNA domains in url-idna.js in favor of
the more comprehensive official set.
Backport-PR-URL: https://github.com/nodejs/node/pull/17365
PR-URL: https://github.com/nodejs/node/pull/13362
Refs: https://github.com/whatwg/url/pull/309
Refs: https://github.com/w3c/web-platform-tests/pull/5976
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com >
2018-02-12 19:28:10 -05:00
James M Snell
699c6638c3
test: add common.hasIntl
...
Backport-PR-URL: https://github.com/nodejs/node/pull/17365
PR-URL: https://github.com/nodejs/node/pull/9246
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Johan Bergström <bugs@bergstroem.nu >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-02-12 19:28:10 -05:00
Timothy Gu
a6d2384c9a
src: clean up MaybeStackBuffer
...
- Add IsInvalidated() method
- Add capacity() method for finding out the actual capacity, not the
current size, of the buffer
- Make IsAllocated() work for invalidated buffers
- Allow multiple calls to AllocateSufficientStorage() and Invalidate()
- Assert buffer is malloc'd in Release()
- Assert buffer has not been invalidated in AllocateSufficientStorage()
- Add more descriptive comments describing the purpose of the methods
- Add cctest for MaybeStackBuffer
Backport-PR-URL: https://github.com/nodejs/node/pull/17365
PR-URL: https://github.com/nodejs/node/pull/11464
Reviewed-By: Steven R Loomis <srloomis@us.ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:09 -05:00
Daniel Bevenius
ddd9d85681
crypto: remove BIO_set_shutdown
...
I've not been able to find any reason for calling
BIO_set_shutdown(bio, 1). This is done by default for the following
versions of OpenSSL:
https://github.com/openssl/openssl/blob/OpenSSL_1_1_0/
crypto/bio/bio_lib.c#L26
https://github.com/openssl/openssl/blob/OpenSSL_1_0_1/
crypto/bio/bio_lib.c#L90
https://github.com/openssl/openssl/blob/OpenSSL_1_0_2/
crypto/bio/bio_lib.c#L88
https://github.com/openssl/openssl/blob/OpenSSL_1_0_0/
crypto/bio/bio_lib.c#L90
This commit removes the call and the comment.
Backport-PR-URL: https://github.com/nodejs/node/pull/17784
PR-URL: https://github.com/nodejs/node/pull/17542
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-02-12 19:28:09 -05:00
Daniel Bevenius
9f3b4ad5bd
src: fix incorrect macro comment
...
Commit de168b4b4a ("src: guard
bundled_ca/openssl_ca with HAVE_OPENSSL") included an incorrect end
macro comment which this commit fixes.
PR-URL: https://github.com/nodejs/node/pull/12688
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Michaël Zasso <targos@protonmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:09 -05:00
Daniel Bevenius
2b29cea1b4
src: guard bundled_ca/openssl_ca with HAVE_OPENSSL
...
Currently, the following warning will be reported when configuring
without-ssl:
../src/node.cc:3653:8: warning: unused variable 'use_bundled_ca'
[-Wunused-variable]
bool use_bundled_ca = false;
^
../src/node.cc:3654:8: warning: unused variable 'use_openssl_ca'
[-Wunused-variable]
bool use_openssl_ca = false;
^
I missed this when working on
commit 8a7db9d4b5 ("src: add
--use-bundled-ca --use-openssl-ca check").
Refs: https://github.com/nodejs/node/pull/12087
Backport-PR-URL: https://github.com/nodejs/node/pull/17783
PR-URL: https://github.com/nodejs/node/pull/12302
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-02-12 19:28:08 -05:00
Daniel Bevenius
758dc81e8d
src: add --use-bundled-ca --use-openssl-ca check
...
The --use-bundled-ca and --use-openssl-ca command line arguments are
mutually exclusive but can both be used on the same command line.
This commit adds a check if both options are used.
Fixes: https://github.com/nodejs/node/issues/12083
Backport-PR-URL: https://github.com/nodejs/node/pull/17783
PR-URL: https://github.com/nodejs/node/pull/12087
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Richard Lau <riclau@uk.ibm.com >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
2018-02-12 19:28:08 -05:00
cjihrig
2d4fca2c41
src: add process.ppid
...
Fixes: https://github.com/nodejs/node/issues/14957
PR-URL: https://github.com/nodejs/node/pull/16839
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:08 -05:00
cjihrig
a1d7469aef
deps: upgrade libuv to 1.16.1
...
PR-URL: https://github.com/nodejs/node/pull/16835
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:07 -05:00
JP Wesselink
18803bc409
tools, build: refactor macOS installer
...
Creates macOS pkg installer by using `pkgbuild` and `productbuild`.
Removes previous npm installation before installing npm.
Packages carry correct version attributes.
Support for intl installer features, defaults to `en`.
Fancy formatted license.
Renamed `osx` references to `macOS`.
Optional installation of npm.
PR-URL: https://github.com/nodejs/node/pull/15179
Fixes: https://github.com/nodejs/node/issues/15012
Refs: https://github.com/nodejs/node/pull/5656
Refs: https://github.com/nodejs/node/pull/2571
Refs: https://github.com/nodejs/node/pull/7097
Reviewed-By: Lance Ball <lball@redhat.com >
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2018-02-12 19:28:07 -05:00
Bryan English
365dba2195
test: fix flaky test-crypto-classes.js
...
On non-FIPS, we can instantiate DiffieHellman with 256 instead of 1024.
This should be quite a bit faster, and therefore prevent the timeouts.
Backport-PR-URL: https://github.com/nodejs/node/pull/16245
PR-URL: https://github.com/nodejs/node/pull/15662
Fixes: https://github.com/nodejs/node/issues/15655
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2018-02-12 19:28:06 -05:00
Bryan English
f3b3437e48
crypto: expose ECDH class
...
For consistency with the rest of the crypto classes, exposes the ECDH
class. Originally, only the createECDH function was exposed, and there
was no real reason to hide the class.
Backport-PR-URL: https://github.com/nodejs/node/pull/16245
PR-URL: https://github.com/nodejs/node/pull/8188
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2018-02-12 19:28:06 -05:00
Bryan English
d29a6202e7
test: crypto createClass instanceof Class
...
The crypto classes are also exposed as createClass for each class. This
tests that each of them returns an instance of the class in question.
Backport-PR-URL: https://github.com/nodejs/node/pull/16245
PR-URL: https://github.com/nodejs/node/pull/8188
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Rich Trott <rtrott@gmail.com >
2018-02-12 19:28:06 -05:00
cjihrig
7b801b5f83
test: don't skip when common.mustCall() is pending
...
The test parallel/test-dgram-multicast-set-interface.js was
calling common.skip() on hosts that do not support IPv6. However,
by this point, there were several outstanding common.mustCall()
invocations. The process.exit() in common.skip() triggered
those common.mustCall()s as errors.
Fixes: https://github.com/nodejs/node/issues/15419
PR-URL: https://github.com/nodejs/node/pull/15421
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Rich Trott <rtrott@gmail.com >
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Brian White <mscdex@mscdex.net >
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com >
2018-02-12 19:28:05 -05:00
Will Young
8f2e52abd7
dgram: added setMulticastInterface()
...
Add wrapper for uv's uv_udp_set_multicast_interface which provides the
sender side mechanism to explicitly select an interface. The
equivalent receiver side mechanism is the optional 2nd argument of
addMembership().
PR-URL: https://github.com/nodejs/node/pull/7855
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
2018-02-12 19:28:05 -05:00
James M Snell
ce136392fb
console: add console.count() and console.clear()
...
Both are simple utility functions defined by the WHATWG
console spec (https://console.spec.whatwg.org/ ).
PR-URL: https://github.com/nodejs/node/pull/12678
Ref: https://github.com/nodejs/node/issues/12675
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com >
Reviewed-By: Timothy Gu <timothygu99@gmail.com >
Reviewed-By: Tobias Nießen <tniessen@tnie.de >
2018-02-12 19:28:05 -05:00
Alexey Orlenko
3b9fea0782
repl: improve require() autocompletion
...
Currently REPL supports autocompletion for core modules and those found
in node_modules. This commit adds tab completion for modules relative
to the current directory.
PR-URL: https://github.com/nodejs/node/pull/14409
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Timothy Gu <timothygu99@gmail.com >
Reviewed-By: Khaidi Chu <i@2333.moe >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:04 -05:00
Sam Roberts
6a27774882
net: return this from getConnections()
...
PR-URL: https://github.com/nodejs/node/pull/13553
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Roman Reiss <me@silverwind.io >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-02-12 19:28:04 -05:00
Sam Roberts
063c4fa345
lib: return this from net.Socket.end()
...
PR-URL: https://github.com/nodejs/node/pull/13481
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: Brian White <mscdex@mscdex.net >
2018-02-12 19:28:04 -05:00
Sakthipriyan Vairamani (thefourtheye)
43a2bc040f
doc: improve randomfill and fix broken link
...
This patch replaces the word `buf` with `buffer` and fixes the broken
link to `randomfill`.
PR-URL: https://github.com/nodejs/node/pull/12541
Reviewed-By: Evan Lucas <evanlucas@me.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
2018-02-12 19:28:03 -05:00
Evan Lucas
6f62f83468
crypto: add randomFill and randomFillSync
...
crypto.randomFill and crypto.randomFillSync are similar to
crypto.randomBytes, but allow passing in a buffer as the first
argument. This allows us to reuse buffers to prevent having to
create a new one on every call.
PR-URL: https://github.com/nodejs/node/pull/10209
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
2018-02-12 19:28:00 -05:00
Roman Reiss
7af1ad0ec1
util: add %i and %f formatting specifiers
...
This change brings formatting specifiers available in `util.format` and
consequently, `console.*` closer to what is supported in all major
browsers.
- `%i` is introduced to format integer values.
- `%f` is introduced to format floating point values.
Fixes: https://github.com/nodejs/node/issues/10292
PR-URL: https://github.com/nodejs/node/pull/10308
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-01-15 16:23:08 -05:00
Fedor Indutny
00b279087e
tls: accept lookup option for tls.connect()
...
`net.connect()` and consequently `http.Agent` support custom DNS
`lookup` option. However, as we move to `https.Agent` - this option no
longer works because it is not proxied by `tls.connect`.
Fix this inconsistency by passing it down to `net.connect`.
PR-URL: https://github.com/nodejs/node/pull/12839
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com >
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
Reviewed-By: Sam Roberts <vieuxtech@gmail.com >
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
2018-01-11 13:04:34 -05:00
Anatoli Papirovski
a09e2fd43b
net: fix timeout with null handle
...
This commit handles the case where _onTimeout is called with a
null handle.
Backport-PR-URL: https://github.com/nodejs/node/pull/16420
Refs: https://github.com/nodejs/node/pull/15791
Fixes: https://github.com/nodejs/node/issues/16484
PR-URL: https://github.com/nodejs/node/pull/16489
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
2018-01-02 14:06:34 -05:00
Anatoli Papirovski
a301c1a0e0
net: fix timeouts during long writes
...
Add updateWriteQueueSize which updates and returns queue size
(net & tls). Make _onTimeout check whether an active write
is ongoing and if so, call _unrefTimer rather than emitting
a timeout event.
Add http & https test that checks whether long-lasting (but
active) writes timeout or can finish writing as expected.
Backport-PR-URL: https://github.com/nodejs/node/pull/16420
PR-URL: https://github.com/nodejs/node/pull/15791
Fixes: https://github.com/nodejs/node/issues/15082
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com >
2018-01-02 14:06:34 -05:00
Anatoli Papirovski
521dc2511f
tls: properly track writeQueueSize during writes
...
Make writeQueueSize represent the actual size of the write queue
within the TLS socket. Add tls test to confirm that bufferSize
works as expected.
Backport-PR-URL: https://github.com/nodejs/node/pull/16420
PR-URL: https://github.com/nodejs/node/pull/15791
Fixes: https://github.com/nodejs/node/issues/15005
Refs: https://github.com/nodejs/node/pull/15006
Reviewed-By: Anna Henningsen <anna@addaleax.net >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Refael Ackermann <refack@gmail.com >
Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com >
2018-01-02 14:06:34 -05:00
jlvivero
b6ce918e0a
stream: fix disparity between buffer and the count
...
This changes the disparity of bufferedRequestCount and the actual buffer
on file _stream_writable.js
PR-URL: https://github.com/nodejs/node/pull/15661
Fixes: https://github.com/nodejs/node/issues/6758
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Matteo Collina <matteo.collina@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-01-02 14:06:34 -05:00
Myles Borins
ef0213c0b8
doc: move Code of Conduct to admin repo
...
The CoC and moderation guidelines now live in the Admin repo.
This PR updates the copy of CODE_OF_CONDUCT.md and references in
other documents to the proper location.
PR-URL: https://github.com/nodejs/node/pull/17301
Reviewed-By: Jon Moss <me@jonathanmoss.me >
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com >
2018-01-02 14:06:34 -05:00
Tobias Nießen
1d706026a7
tools: make doc tool a bit more readable
...
Backport-PR-URL: https://github.com/nodejs/node/pull/17788
PR-URL: https://github.com/nodejs/node/pull/17125
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-01-02 14:06:34 -05:00
Tobias Nießen
b8a5d6dbbc
tools: remove useless function declaration
...
Backport-PR-URL: https://github.com/nodejs/node/pull/17788
PR-URL: https://github.com/nodejs/node/pull/17125
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
2018-01-02 14:06:34 -05:00
Rich Trott
4f6dd9649f
test,doc: do not indicate that non-functions "return" values
...
Update documentation for test `common` module so that properties that
are not functions do not specify a return type and functions that do
return values specify the type.
PR-URL: https://github.com/nodejs/node/pull/17267
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com >
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2018-01-02 14:06:34 -05:00
Myles Borins
99af46e92c
Working on v6.12.4
...
PR-URL: https://github.com/nodejs/node/pull/17776
2018-01-02 14:05:57 -05:00
Myles Borins
d5fbd254ef
2018-01-02, Version 6.12.3 'Boron' (LTS)
...
Notable Changes:
* build:
- configure can now be run from any directory (Gibson Fahnestock)
https://github.com/nodejs/node/pull/17321
PR-URL: https://github.com/nodejs/node/pull/17776
v6.12.3
2018-01-02 12:48:26 -05:00
Rich Trott
a528d573ce
test: remove hidden use of common.PORT in parallel tests
...
common.hasMultiLocalhost() uses common.PORT under the hood. This is
problematic in parallel tests because another test using port 0 to
get an arbitrary open port may end up getting common.PORT before the
test using common.PORT gets it.
Therefore, change common.PORT to port 0 in common.hasMultiLocalhost().
Backport-PR-URL: https://github.com/nodejs/node/pull/17771
PR-URL: https://github.com/nodejs/node/pull/17466
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Jon Moss <me@jonathanmoss.me >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2017-12-19 21:37:35 -05:00
薛定谔的猫
b1b975370f
benchmark,path: remove unused variables
...
PR-URL: https://github.com/nodejs/node/pull/15789
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: James M Snell <jasnell@gmail.com >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
2017-12-19 21:13:10 -05:00
Rich Trott
dbf5ddbc97
test: refactor test-child-process-pass-fd
...
Add a comment explaining the test (especailly why it forks 80 processes.
Use destructuring and an arrow function callback.
PR-URL: https://github.com/nodejs/node/pull/17596
Reviewed-By: Khaidi Chu <i@2333.moe >
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
Reviewed-By: Minwoo Jung <minwoo@nodesource.com >
2017-12-20 01:25:46 +00:00
cjihrig
ad0d878772
tools: simplify buffer-constructor rule
...
PR-URL: https://github.com/nodejs/node/pull/17572
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
2017-12-20 01:24:07 +00:00
cjihrig
5383422672
tools: simplify prefer-assert-methods rule
...
PR-URL: https://github.com/nodejs/node/pull/17572
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
2017-12-20 01:24:07 +00:00
cjihrig
3e70ee84fb
tools: simplify prefer-common-mustnotcall rule
...
PR-URL: https://github.com/nodejs/node/pull/17572
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com >
2017-12-20 01:24:07 +00:00
Daniel Bevenius
2d74af0184
src: remove unused include node_crypto_clienthello
...
This commit removes the include of node.h which does not seem to be
used.
PR-URL: https://github.com/nodejs/node/pull/17546
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl >
Reviewed-By: Colin Ihrig <cjihrig@gmail.com >
2017-12-20 01:16:33 +00:00
Rich Trott
dcee5edef7
doc: simplify and clarify FIPS text in BUILDING.md
...
PR-URL: https://github.com/nodejs/node/pull/17538
Fixes: https://github.com/nodejs/node/issues/17536
Reviewed-By: Luigi Pinca <luigipinca@gmail.com >
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com >
Reviewed-By: Jon Moss <me@jonathanmoss.me >
2017-12-20 01:15:39 +00:00