mirror of
https://github.com/nodejs/node.git
synced 2026-11-25 23:01:06 -05:00
doc: add options description for send APIs
Describes the meaning of the boolean return in process.send() (doc/api/process.md) and worker.send() (doc/api/cluster.md) as described in subprocess.send() (doc/api/child_process.md) Fixes: https://github.com/nodejs/node/issues/26995 PR-URL: https://github.com/nodejs/node/pull/29868 Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
This commit is contained in:
1 parent
d0f5bc1aa7
commit
98d31da342
2 files changed
+12
-2
No files matched your search
+7
-1
@@ -456,7 +456,7 @@ Workers will call `process.exit(0)` if the `'disconnect'` event occurs
|
||||
on `process` and `.exitedAfterDisconnect` is not `true`. This protects against
|
||||
accidental disconnection.
|
||||
|
||||
### worker.send(message\[, sendHandle\]\[, callback\])
|
||||
### worker.send(message\[, sendHandle\[, options\]\]\[, callback\])
|
||||
<!-- YAML
|
||||
added: v0.7.0
|
||||
changes:
|
||||
@@ -467,6 +467,12 @@ changes:
|
||||
|
||||
* `message` {Object}
|
||||
* `sendHandle` {Handle}
|
||||
* `options` {Object} The `options` argument, if present, is an object used to
|
||||
parameterize the sending of certain types of handles. `options` supports
|
||||
the following properties:
|
||||
* `keepOpen` {boolean} A value that can be used when passing instances of
|
||||
`net.Socket`. When `true`, the socket is kept open in the sending process.
|
||||
**Default:** `false`.
|
||||
* `callback` {Function}
|
||||
* Returns: {boolean}
|
||||
|
||||
|
||||
+5
-1
@@ -1940,7 +1940,11 @@ added: v0.5.9
|
||||
|
||||
* `message` {Object}
|
||||
* `sendHandle` {net.Server|net.Socket}
|
||||
* `options` {Object}
|
||||
* `options` {Object} used to parameterize the sending of certain types of
|
||||
handles.`options` supports the following properties:
|
||||
* `keepOpen` {boolean} A value that can be used when passing instances of
|
||||
`net.Socket`. When `true`, the socket is kept open in the sending process.
|
||||
**Default:** `false`.
|
||||
* `callback` {Function}
|
||||
* Returns: {boolean}
|
||||
|
||||
|
||||
Reference in new issue
Block a user