0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-29 07:00:59 +01:00
nodejs/doc/api
Dan Fabulich ff74e35c0b
process: add unhandled-rejection throw and warn-with-error-code
This PR defines two new modes for the --unhandled-rejections flag.

The first mode is called "throw". The "throw" mode first emits
unhandledRejection. If this hook is not set, the "throw" mode will
raise the unhandled rejection as an uncaught exception.

The second mode is called "warn-with-error-code". The
"warn-with-error-code" mode first emits unhandledRejection. If this
hook is not set, the "warn-with-error-code" mode will trigger a
warning and set the process's exit code to 1.

The PR doesn't change the default behavior for unhandled rejections.
That will come in a separate PR.

Refs: https://github.com/nodejs/node/pull/33021

PR-URL: https://github.com/nodejs/node/pull/33475
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
2020-06-16 13:03:05 -07:00
..
addons.md doc: remove "currently" from addons.md 2020-06-07 12:36:37 -07:00
assert.md 2020-05-05, Version 14.2.0 (Current) 2020-05-05 20:24:37 +02:00
async_hooks.md doc: add snippet for AsyncResource and EE integration 2020-06-11 12:16:55 +03:00
buffer.md doc: improve buffer.md a tiny bit 2020-05-30 04:28:53 +02:00
child_process.md net: remove long deprecated server.connections property 2020-06-01 08:38:00 -07:00
cli.md process: add unhandled-rejection throw and warn-with-error-code 2020-06-16 13:03:05 -07:00
cluster.md doc: remove default parameter value from header 2020-06-07 11:10:45 -07:00
console.md 2020-05-26, Version 12.17.0 'Erbium' (LTS) 2020-05-26 15:55:39 +02:00
crypto.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
debugger.md doc: update V8 inspector example 2020-06-08 21:31:28 -04:00
deprecations.md doc: fix deprecation "End-of-Life" capitalization 2020-06-02 17:19:42 -04:00
dgram.md doc: fix LTS replaceme tags 2020-04-28 15:23:46 +02:00
dns.md dns: make dns.Resolver timeout configurable 2020-06-01 08:07:59 -07:00
documentation.md doc: add link to sem-ver info 2020-03-02 04:07:33 +00:00
domain.md doc,domain: use code markup/markdown in headers 2019-12-26 21:39:24 -08:00
embedding.md doc: normalize C++ code block info strings 2020-05-23 17:21:20 +02:00
errors.md quic: initial QUIC implementation 2020-06-16 09:23:34 -07:00
esm.md esm: fix loader hooks doc annotations 2020-06-13 20:48:40 -07:00
events.md doc: make events Extends usage consistent 2020-06-08 21:25:25 -04:00
fs.md fs: support util.promisify for fs.readv 2020-05-30 10:17:31 -07:00
globals.md doc: make globals Extends usage consistent 2020-06-08 21:25:26 -04:00
http2.md 2020-06-02, Version 10.21.0 'Dubnium' (LTS) 2020-06-02 20:35:52 +02:00
http.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
https.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
index.md quic: initial QUIC implementation 2020-06-16 09:23:34 -07:00
inspector.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
intl.md doc: normalize shell code block info strings 2020-05-25 19:12:38 +02:00
modules.md doc: update ``txt `fandamental and ``raw code blocks 2020-05-30 03:43:39 +02:00
n-api.md 2020-05-26, Version 12.17.0 'Erbium' (LTS) 2020-05-26 15:55:39 +02:00
net.md quic: initial QUIC implementation 2020-06-16 09:23:34 -07:00
os.md 2020-05-26, Version 12.17.0 'Erbium' (LTS) 2020-05-26 15:55:39 +02:00
path.md doc: fixed a grammatical error in path.md 2020-05-23 17:13:28 +02:00
perf_hooks.md doc: make perf_hooks Extends usage consistent 2020-06-08 21:25:25 -04:00
policy.md doc: normalize Bash code block info strings 2020-05-25 19:08:45 +02:00
process.md doc: outline when origin is set to unhandledRejection 2020-05-30 04:21:21 +02:00
punycode.md doc,punycode: use code markup/markdown in headers 2019-12-26 21:39:30 -08:00
querystring.md doc,querystring: use code markup/markdown in headers 2019-12-26 21:39:30 -08:00
quic.md quic: initial QUIC implementation 2020-06-16 09:23:34 -07:00
readline.md doc: fix readline key binding documentation 2020-05-20 17:05:01 +02:00
repl.md doc: remove "currently" from repl.md 2020-06-07 12:36:43 -07:00
report.md doc: update ``txt `fandamental and ``raw code blocks 2020-05-30 03:43:39 +02:00
stream.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
string_decoder.md doc: add support encoding link on string_decoder.md 2020-03-11 17:06:13 +01:00
synopsis.md doc: move Usage and Example to same header level 2019-07-09 19:45:20 -07:00
timers.md doc,timers: use code markup/markdown in headers 2019-12-26 21:39:32 -08:00
tls.md doc: use single quotes in --tls-cipher-list 2020-06-11 09:54:15 +02:00
tracing.md doc: update ``txt `fandamental and ``raw code blocks 2020-05-30 03:43:39 +02:00
tty.md doc: normalize Bash code block info strings 2020-05-25 19:08:45 +02:00
url.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
util.md util: restrict custom inspect function + vm.Context interaction 2020-06-11 21:44:34 +02:00
v8.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
vm.md doc: standardize constructor doc header layout 2020-06-10 05:31:21 -07:00
wasi.md wasi: allow WASI stdio to be configured 2020-05-30 04:28:02 +02:00
worker_threads.md worker: emit 'messagerror' events for failed deserialization 2020-06-14 14:53:40 +02:00
zlib.md zlib: add maxOutputLength option 2020-06-09 17:26:10 +02:00