doc: remove "note that" from cluster.md
Refs: https://github.com/nodejs/remark-preset-lint-node/pull/16 PR-URL: https://github.com/nodejs/node/pull/28329 Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
parent
7023cb4e86
commit
c9275cdb0b
@ -50,8 +50,7 @@ Worker 6056 started
|
||||
Worker 5644 started
|
||||
```
|
||||
|
||||
Please note that on Windows, it is not yet possible to set up a named pipe
|
||||
server in a worker.
|
||||
On Windows, it is not yet possible to set up a named pipe server in a worker.
|
||||
|
||||
## How It Works
|
||||
|
||||
@ -277,7 +276,7 @@ In the master, an internal message is sent to the worker causing it to call
|
||||
|
||||
Causes `.exitedAfterDisconnect` to be set.
|
||||
|
||||
Note that after a server is closed, it will no longer accept new connections,
|
||||
After a server is closed, it will no longer accept new connections,
|
||||
but connections may be accepted by any other listening worker. Existing
|
||||
connections will be allowed to close as usual. When no more connections exist,
|
||||
see [`server.close()`][], the IPC channel to the worker will close allowing it
|
||||
@ -287,8 +286,8 @@ The above applies *only* to server connections, client connections are not
|
||||
automatically closed by workers, and disconnect does not wait for them to close
|
||||
before exiting.
|
||||
|
||||
Note that in a worker, `process.disconnect` exists, but it is not this function,
|
||||
it is [`disconnect`][].
|
||||
In a worker, `process.disconnect` exists, but it is not this function;
|
||||
it is [`disconnect()`][].
|
||||
|
||||
Because long living server connections may block workers from disconnecting, it
|
||||
may be useful to send a message, so application specific actions may be taken to
|
||||
@ -403,8 +402,8 @@ Causes `.exitedAfterDisconnect` to be set.
|
||||
|
||||
This method is aliased as `worker.destroy()` for backwards compatibility.
|
||||
|
||||
Note that in a worker, `process.kill()` exists, but it is not this function,
|
||||
it is [`kill`][].
|
||||
In a worker, `process.kill()` exists, but it is not this function;
|
||||
it is [`kill()`][].
|
||||
|
||||
### worker.process
|
||||
<!-- YAML
|
||||
@ -419,7 +418,7 @@ is stored.
|
||||
|
||||
See: [Child Process module][].
|
||||
|
||||
Note that workers will call `process.exit(0)` if the `'disconnect'` event occurs
|
||||
Workers will call `process.exit(0)` if the `'disconnect'` event occurs
|
||||
on `process` and `.exitedAfterDisconnect` is not `true`. This protects against
|
||||
accidental disconnection.
|
||||
|
||||
@ -758,14 +757,14 @@ changes:
|
||||
`setupMaster` is used to change the default 'fork' behavior. Once called,
|
||||
the settings will be present in `cluster.settings`.
|
||||
|
||||
Note that:
|
||||
Any settings changes only affect future calls to `.fork()` and have no
|
||||
effect on workers that are already running.
|
||||
|
||||
* Any settings changes only affect future calls to `.fork()` and have no
|
||||
effect on workers that are already running.
|
||||
* The *only* attribute of a worker that cannot be set via `.setupMaster()` is
|
||||
the `env` passed to `.fork()`.
|
||||
* The defaults above apply to the first call only, the defaults for later
|
||||
calls is the current value at the time of `cluster.setupMaster()` is called.
|
||||
The only attribute of a worker that cannot be set via `.setupMaster()` is
|
||||
the `env` passed to `.fork()`.
|
||||
|
||||
The defaults above apply to the first call only; the defaults for later
|
||||
calls are the current values at the time of `cluster.setupMaster()` is called.
|
||||
|
||||
```js
|
||||
const cluster = require('cluster');
|
||||
@ -846,8 +845,8 @@ socket.on('data', (id) => {
|
||||
[`child_process` event: `'exit'`]: child_process.html#child_process_event_exit
|
||||
[`child_process` event: `'message'`]: child_process.html#child_process_event_message
|
||||
[`cluster.settings`]: #cluster_cluster_settings
|
||||
[`disconnect`]: child_process.html#child_process_subprocess_disconnect
|
||||
[`kill`]: process.html#process_process_kill_pid_signal
|
||||
[`disconnect()`]: child_process.html#child_process_subprocess_disconnect
|
||||
[`kill()`]: process.html#process_process_kill_pid_signal
|
||||
[`process` event: `'message'`]: process.html#process_event_message
|
||||
[`server.close()`]: net.html#net_event_close
|
||||
[`worker.exitedAfterDisconnect`]: #cluster_worker_exitedafterdisconnect
|
||||
|
Loading…
x
Reference in New Issue
Block a user