summaryrefslogtreecommitdiff
path: root/doc/api/cluster.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/api/cluster.md')
-rw-r--r--doc/api/cluster.md20
1 files changed, 10 insertions, 10 deletions
diff --git a/doc/api/cluster.md b/doc/api/cluster.md
index 7c0baa36ff..b420645bb4 100644
--- a/doc/api/cluster.md
+++ b/doc/api/cluster.md
@@ -117,7 +117,7 @@ also be used for other use cases requiring worker processes.
added: v0.7.0
-->
-A Worker object contains all public information and method about a worker.
+A `Worker` object contains all public information and method about a worker.
In the master it can be obtained using `cluster.workers`. In a worker
it can be obtained using `cluster.worker`.
@@ -497,7 +497,7 @@ cluster.on('exit', (worker, code, signal) => {
});
```
-See [child_process event: `'exit'`][].
+See [`child_process` event: `'exit'`][].
## Event: 'fork'
<!-- YAML
@@ -573,7 +573,7 @@ changes:
Emitted when the cluster master receives a message from any worker.
-See [child_process event: `'message'`][].
+See [`child_process` event: `'message'`][].
Before Node.js v6.0, this event emitted only the message and the handle,
but not the worker object, contrary to what the documentation stated.
@@ -813,10 +813,10 @@ A hash that stores the active worker objects, keyed by `id` field. Makes it
easy to loop through all the workers. It is only available in the master
process.
-A worker is removed from cluster.workers after the worker has disconnected _and_
-exited. The order between these two events cannot be determined in advance.
-However, it is guaranteed that the removal from the cluster.workers list happens
-before last `'disconnect'` or `'exit'` event is emitted.
+A worker is removed from `cluster.workers` after the worker has disconnected
+_and_ exited. The order between these two events cannot be determined in
+advance. However, it is guaranteed that the removal from the `cluster.workers`
+list happens before last `'disconnect'` or `'exit'` event is emitted.
```js
// Go through all workers
@@ -840,12 +840,12 @@ socket.on('data', (id) => {
[`ChildProcess.send()`]: child_process.html#child_process_subprocess_send_message_sendhandle_options_callback
[`child_process.fork()`]: child_process.html#child_process_child_process_fork_modulepath_args_options
+[`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
[`process` event: `'message'`]: process.html#process_event_message
[`server.close()`]: net.html#net_event_close
[`worker.exitedAfterDisconnect`]: #cluster_worker_exitedafterdisconnect
[Child Process module]: child_process.html#child_process_child_process_fork_modulepath_args_options
-[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