Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v18.1.0 release proposal #42943

Merged
merged 91 commits into from
May 3, 2022
Merged
Changes from 1 commit
Commits
Show all changes
91 commits
Select commit Hold shift + click to select a range
18ae2c3
tools: lint osx shell scripts
LiviaMedeiros Apr 14, 2022
ef5ab81
doc: fix `added:` info for `outgoingMessage.{,un}cork()`
lpinca Apr 14, 2022
2a07a9f
doc: document the 'close' and 'finish' events
lpinca Apr 14, 2022
be44b1f
test: improve test coverage of internal/blob
kuriyosh Apr 14, 2022
deb3cf4
test: remove the legacy url parser function
cola119 Apr 14, 2022
78a860a
test_runner: add initial CLI runner
cjihrig Apr 15, 2022
2f38b48
meta: move mmarchini to emeritus
mmarchini Apr 16, 2022
6b7c35e
doc: delete mdb_v8 from diagnostic tooling support tiers
tony-go Apr 16, 2022
1a7af63
src: large page attributing an id on Linux
devnexen Apr 17, 2022
294664e
deps: upgrade npm to 8.7.0
Apr 14, 2022
c50309c
doc: fix `added:` info for `outgoingMessage.writable*`
lpinca Apr 17, 2022
14893c5
meta: update AUTHORS
nodejs-github-bot Apr 17, 2022
47c0481
tools: update lint-md-dependencies
nodejs-github-bot Apr 17, 2022
93fd77a
tools: update doc to [email protected]
nodejs-github-bot Apr 17, 2022
4694f5b
async_hooks: avoid decrementing iterator after erase
dygabo Apr 17, 2022
459546b
benchmark: fix misc/startup failure
aduh95 Apr 17, 2022
d77c59d
doc: improve fragment (`:target`) anchors behavior on HTML version
aduh95 Apr 17, 2022
4c30936
doc: copyedit http.OutgoingMessage documentation
lpinca Apr 17, 2022
222b3e6
doc: close tag in n-api.md
LiviaMedeiros Apr 18, 2022
962d80b
doc: add documentation for inherited methods
lpinca Apr 18, 2022
29c8411
bootstrap: move embedded snapshot to SnapshotBuilder
joyeecheung Apr 11, 2022
6bd2420
bootstrap: use the isolate snapshot in workers
joyeecheung Apr 11, 2022
d311916
test: fix calculations in test-worker-resource-limits
joyeecheung Apr 11, 2022
025b3e7
doc: consolidate use of multiple-byte units
aduh95 Apr 19, 2022
7c97347
build: improve the format-cpp error message
RaisinTen Apr 19, 2022
c3922af
worker: add hasRef() to the handle object
RaisinTen Apr 19, 2022
46c880b
doc: clarify core modules that can be loaded without a prefix
aduh95 Apr 19, 2022
3d65a3b
doc: add `node:` prefix for all core modules
aduh95 Apr 20, 2022
b7e9dd0
src: use `node:` prefix in example
aduh95 Apr 20, 2022
5d15eb1
build: fix format-cpp
RaisinTen Apr 20, 2022
1976284
src: define fs.constants.S_IWUSR & S_IRUSR for Win
ilg-ul Apr 21, 2022
33ac027
meta: move one or more collaborators to emeritus
nodejs-github-bot Apr 18, 2022
6225370
doc: fix version history for Loaders API
aduh95 Apr 21, 2022
c32f76d
doc: fix example in assert.md
LiviaMedeiros Apr 21, 2022
8476ffb
test: use `assert.match()` instead of `assert(regex.test())`
aduh95 Apr 21, 2022
6fa080c
doc: delete heapdump from diagnostic tooling support tiers
tony-go Apr 21, 2022
d9f3f05
doc: fix outdated documentation for `family` property
aduh95 Apr 21, 2022
59da133
doc: add maintaining-webassembly.md
mhdawson Apr 8, 2022
c46e7bb
doc: add @kuriyosh to collaborators
kuriyosh Apr 22, 2022
c6c1dc5
doc: order `vm.Module` linker arguments correctly
SimenB Apr 22, 2022
b0f7c4c
lib,src: implement WebAssembly Web API
tniessen Apr 23, 2022
a19fb60
v8: export more fields in getHeapStatistics
theanarkh Apr 23, 2022
7681e60
crypto: validate `this` in all webcrypto methods and getters
panva Apr 23, 2022
f9994e2
build: improve reliability of find_python.cmd script
lpinca Apr 23, 2022
d33cbab
lib: remove experimental warning from FormData
meixg Apr 24, 2022
4050b0d
build: enable V8's shared read-only heap
targos Apr 24, 2022
494650c
src,crypto: remove uses of AllocatedBuffer from crypto_ec.cc
RaisinTen Apr 24, 2022
0e16120
errors,vm: update error and use cause
devsnek Apr 22, 2022
37364ab
test: fix flaky HTTP server tests
tniessen Apr 24, 2022
fdc6503
meta: update AUTHORS
nodejs-github-bot Apr 24, 2022
97fc00a
tools: update eslint to 8.14.0
nodejs-github-bot Apr 24, 2022
1b5856a
wasi: remove unecessary null check
mhdawson Apr 24, 2022
9b61ac2
doc: update WebAssembly strategy with Wasm Web API
tniessen Apr 25, 2022
c3c5fe7
tools: bump jsdoccomment from 0.22.1 to 0.29.0
Trott Apr 25, 2022
7b70144
test: skip test that cannot pass under --node-builtin-modules-path
GeoffreyBooth Apr 25, 2022
ad82694
lib,src: use Response URL as WebAssembly location
tniessen Apr 25, 2022
2d76f72
doc: elevate node-clinic diagnostic tier
RafaelGSS Apr 20, 2022
cd2f5a4
doc: add primordials guidelines
aduh95 May 11, 2021
48bbb73
fs: fix mkdirSync so ENOSPC is correctly reported
santigimeno Apr 26, 2022
0725064
test: fix port in net-perf_hooks
LiviaMedeiros Apr 26, 2022
2f849a4
doc: fix markdown formatting in primordials.md
tniessen Apr 27, 2022
59c07a9
test: check ecdsa psychic signature
panva Apr 27, 2022
b85a11c
test: improve lib/internal/test_runner/test.js coverage
fossamagna Apr 27, 2022
fe65996
doc: clarify guide on testing internal errors
LiviaMedeiros Apr 27, 2022
a6e1e7a
doc,test: add tests and docs for duplex.fromWeb and duplex.toWeb
ErickWendel Apr 28, 2022
336242a
errors,console: refactor to use ES2021 syntax
xtx1130 Apr 28, 2022
7fae2c9
deps: add template for generated headers
danbev Apr 5, 2022
e8734a4
deps: add note about removing asm archs
danbev Apr 14, 2022
6dc1f82
deps: remove archs/aix64-gcc
danbev Apr 9, 2022
8dc71f2
deps: remove aix-gcc architecture
danbev Apr 14, 2022
4abe987
deps: remove linux-ppc architecture
danbev Apr 14, 2022
2798929
deps: remove linux-ppc64 architecture
danbev Apr 14, 2022
1102922
deps: upgrade npm to 8.8.0
npm-robot Apr 28, 2022
37ca110
src: make --no-node-snapshot a per-process option
joyeecheung Apr 28, 2022
e15d22c
doc: initial version of security-model-strategy.md
mhdawson Apr 12, 2022
dab15f6
esm: graduate top-level-await to stable
aduh95 Apr 28, 2022
8f2b228
doc: record March 2022 security release steward
richardlau Apr 28, 2022
e313dc6
doc: http2.createServer `options` as optional
daeyeon Apr 28, 2022
227a45b
doc: remove legacy `-J` test.py option from BUILDING.md
LiviaMedeiros Apr 21, 2022
60e461c
doc: reword "test directory"
LiviaMedeiros Apr 21, 2022
e808366
src: turn SSL_CTX_new CHECK/segfault into JS exception
addaleax Apr 28, 2022
3c796f8
test: fix `parallel/test-dgram-udp6-link-local-address`
aduh95 Apr 28, 2022
a0638a2
esm: fix imports from non-file module
aduh95 Apr 29, 2022
4af0fbd
v8: export cpu_profiler_metadata_size in getHeapCodeStatistics
theanarkh Apr 29, 2022
fbda87d
test: simplify test-gc-{http-client,net}-*
lpinca Apr 19, 2022
8e0e576
test: add tests for extracting function name
cola119 May 1, 2022
718d11f
perf_hooks: return different functions in timerify
himself65 Apr 24, 2022
1e7479d
tools: update lint-md-dependencies
nodejs-github-bot May 1, 2022
bf9240a
worker: add hasRef() to MessagePort
RaisinTen May 2, 2022
2a4c826
deps: update undici to 5.1.1
targos May 2, 2022
f35f8a6
2022-05-03, Version 18.1.0 (Current)
targos May 2, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
doc: copyedit http.OutgoingMessage documentation
Fix nits/typos and simplify some sentences.

PR-URL: #42733
Reviewed-By: Paolo Insogna <[email protected]>
Reviewed-By: Matteo Collina <[email protected]>
  • Loading branch information
lpinca authored and targos committed Apr 28, 2022
commit 4c3093606523f4f45dab7f9d1a49c49b7f7b24e4
112 changes: 44 additions & 68 deletions doc/api/http.md
Original file line number Diff line number Diff line change
Expand Up @@ -2455,8 +2455,8 @@ added: v0.1.17
* Extends: {Stream}

This class serves as the parent class of [`http.ClientRequest`][]
and [`http.ServerResponse`][]. It is an abstract of outgoing message from
the perspective of the participants of HTTP transaction.
and [`http.ServerResponse`][]. It is an abstract outgoing message from
the perspective of the participants of an HTTP transaction.

### Event: `'drain'`

Expand All @@ -2480,7 +2480,7 @@ Emitted when the transmission is finished successfully.
added: v0.11.6
-->

Emitted when `outgoingMessage.end` was called.
Emitted after `outgoingMessage.end()` is called.
When the event is emitted, all data has been processed but not necessarily
completely flushed.

Expand All @@ -2494,11 +2494,11 @@ added: v0.3.0

Adds HTTP trailers (headers but at the end of the message) to the message.

Trailers are **only** be emitted if the message is chunked encoded. If not,
the trailer will be silently discarded.
Trailers will **only** be emitted if the message is chunked encoded. If not,
the trailers will be silently discarded.

HTTP requires the `Trailer` header to be sent to emit trailers,
with a list of header fields in its value, e.g.
with a list of header field names in its value, e.g.

```js
message.writeHead(200, { 'Content-Type': 'text/plain',
Expand All @@ -2522,7 +2522,7 @@ deprecated:

> Stability: 0 - Deprecated: Use [`outgoingMessage.socket`][] instead.

Aliases of `outgoingMessage.socket`
Alias of [`outgoingMessage.socket`][].

### `outgoingMessage.cork()`

Expand Down Expand Up @@ -2562,22 +2562,22 @@ changes:

Finishes the outgoing message. If any parts of the body are unsent, it will
flush them to the underlying system. If the message is chunked, it will
send the terminating chunk `0\r\n\r\n`, and send the trailer (if any).
send the terminating chunk `0\r\n\r\n`, and send the trailers (if any).

If `chunk` is specified, it is equivalent to call
If `chunk` is specified, it is equivalent to calling
`outgoingMessage.write(chunk, encoding)`, followed by
`outgoingMessage.end(callback)`.

If `callback` is provided, it will be called when the message is finished.
(equivalent to the callback to event `finish`)
If `callback` is provided, it will be called when the message is finished
(equivalent to a listener of the `'finish'` event).

### `outgoingMessage.flushHeaders()`

<!-- YAML
added: v1.6.0
-->

Compulsorily flushes the message headers
Flushes the message headers.

For efficiency reason, Node.js normally buffers the message headers
until `outgoingMessage.end()` is called or the first chunk of message data
Expand All @@ -2586,7 +2586,7 @@ packet.

It is usually desired (it saves a TCP round-trip), but not when the first
data is not sent until possibly much later. `outgoingMessage.flushHeaders()`
bypasses the optimization and kickstarts the request.
bypasses the optimization and kickstarts the message.

### `outgoingMessage.getHeader(name)`

Expand All @@ -2597,8 +2597,8 @@ added: v0.4.0
* `name` {string} Name of header
* Returns {string | undefined}

Gets the value of HTTP header with the given name. If such a name doesn't
exist in message, it will be `undefined`.
Gets the value of the HTTP header with the given name. If that header is not
set, the returned value will be `undefined`.

### `outgoingMessage.getHeaderNames()`

Expand All @@ -2608,8 +2608,8 @@ added: v7.7.0

* Returns {string\[]}

Returns an array of names of headers of the outgoing outgoingMessage. All
names are lowercase.
Returns an array containing the unique names of the current outgoing headers.
All names are lowercase.

### `outgoingMessage.getHeaders()`

Expand All @@ -2626,8 +2626,8 @@ object are the header names and the values are the respective header
values. All header names are lowercase.

The object returned by the `outgoingMessage.getHeaders()` method does
not prototypically inherit from the JavaScript Object. This means that
typical Object methods such as `obj.toString()`, `obj.hasOwnProperty()`,
not prototypically inherit from the JavaScript `Object`. This means that
typical `Object` methods such as `obj.toString()`, `obj.hasOwnProperty()`,
and others are not defined and will not work.

```js
Expand Down Expand Up @@ -2670,14 +2670,11 @@ Read-only. `true` if the headers were sent, otherwise `false`.
added: v9.0.0
-->

Overrides the pipe method of legacy `Stream` which is the parent class of
`http.outgoingMessage`.

Since `OutgoingMessage` should be a write-only stream,
call this function will throw an `Error`. Thus, it disabled the pipe method
it inherits from `Stream`.
Overrides the `stream.pipe()` method inherited from the legacy `Stream` class
which is the parent class of `http.OutgoingMessage`.

The User should not call this function directly.
Calling this method will throw an `Error` because `outgoingMessage` is a
write-only stream.

### `outgoingMessage.removeHeader(name)`

Expand All @@ -2700,10 +2697,12 @@ added: v0.4.0
-->

* `name` {string} Header name
* `value` {string} Header value
* `value` {any} Header value
* Returns: {this}

Sets a single header value for the header object.
Sets a single header value. If the header already exists in the to-be-sent
headers, its value will be replaced. Use an array of strings to send multiple
headers with the same name.

### `outgoingMessage.setTimeout(msesc[, callback])`

Expand Down Expand Up @@ -2752,8 +2751,7 @@ added:

* {number}

This `outgoingMessage.writableCorked` will return the time how many
`outgoingMessage.cork()` have been called.
The number of times `outgoingMessage.cork()` has been called.

### `outgoingMessage.writableEnded`

Expand All @@ -2763,9 +2761,9 @@ added: v12.9.0

* {boolean}

Readonly, `true` if `outgoingMessage.end()` has been called. Noted that
this property does not reflect whether the data has been flush. For that
purpose, use `message.writableFinished` instead.
Is `true` if `outgoingMessage.end()` has been called. This property does
not indicate whether the data has been flushed. For that purpose, use
`message.writableFinished` instead.

### `outgoingMessage.writableFinished`

Expand All @@ -2775,7 +2773,7 @@ added: v12.7.0

* {boolean}

Readonly. `true` if all data has been flushed to the underlying system.
Is `true` if all data has been flushed to the underlying system.

### `outgoingMessage.writableHighWaterMark`

Expand All @@ -2785,12 +2783,8 @@ added: v12.9.0

* {number}

This `outgoingMessage.writableHighWaterMark` will be the `highWaterMark` of
underlying socket if socket exists. Else, it would be the default
`highWaterMark`.

`highWaterMark` is the maximum amount of data that can be potentially
buffered by the socket.
The `highWaterMark` of the underlying socket if assigned. Otherwise, the default
buffer level when [`writable.write()`][] starts returning false (`16384`).

### `outgoingMessage.writableLength`

Expand All @@ -2800,8 +2794,7 @@ added: v12.9.0

* {number}

Readonly, This `outgoingMessage.writableLength` contains the number of
bytes (or objects) in the buffer ready to send.
The number of buffered bytes.

### `outgoingMessage.writableObjectMode`

Expand All @@ -2811,51 +2804,33 @@ added: v12.9.0

* {boolean}

Readonly, always returns `false`.
Always `false`.

### `outgoingMessage.write(chunk[, encoding][, callback])`

<!-- YAML
added: v0.1.29
changes:
- version: v0.11.6
description: add `callback` argument.
description: The `callback` argument was added.
-->

* `chunk` {string | Buffer}
* `encoding` {string} **Default**: `utf8`
* `callback` {Function}
* Returns {boolean}

If this method is called and the header is not sent, it will call
`this._implicitHeader` to flush implicit header.
If the message should not have a body (indicated by `this._hasBody`),
the call is ignored and `chunk` will not be sent. It could be useful
when handling a particular message which must not include a body.
e.g. response to `HEAD` request, `204` and `304` response.
Sends a chunk of the body. This method can be called multiple times.

`chunk` can be a string or a buffer. When `chunk` is a string, the
`encoding` parameter specifies how to encode `chunk` into a byte stream.
`callback` will be called when the `chunk` is flushed.
The `encoding` argument is only relevant when `chunk` is a string. Defaults to
`'utf8'`.

If the message is transferred in chucked encoding
(indicated by `this.chunkedEncoding`), `chunk` will be flushed as
one chunk among a stream of chunks. Otherwise, it will be flushed as the
body of message.

This method handles the raw body of the HTTP message and has nothing to do
with higher-level multi-part body encodings that may be used.

If it is the first call to this method of a message, it will send the
buffered header first, then flush the `chunk` as described above.

The second and successive calls to this method will assume the data
will be streamed and send the new data separately. It means that the response
is buffered up to the first chunk of the body.
The `callback` argument is optional and will be called when this chunk of data
is flushed.

Returns `true` if the entire data was flushed successfully to the kernel
buffer. Returns `false` if all or part of the data was queued in the user
memory. Event `drain` will be emitted when the buffer is free again.
memory. The `'drain'` event will be emitted when the buffer is free again.

## `http.METHODS`

Expand Down Expand Up @@ -3542,4 +3517,5 @@ try {
[`writable.destroy()`]: stream.md#writabledestroyerror
[`writable.destroyed`]: stream.md#writabledestroyed
[`writable.uncork()`]: stream.md#writableuncork
[`writable.write()`]: stream.md#writablewritechunk-encoding-callback
[initial delay]: net.md#socketsetkeepaliveenable-initialdelay