Skip to content

Commit

Permalink
docs: add section about unhandled rejections in config docs (#3323)
Browse files Browse the repository at this point in the history
* docs: add section about unhandled rejections in config docs


Co-authored-by: Trent Mick <trent.mick@elastic.co>
  • Loading branch information
david-luna and trentm committed May 16, 2023
1 parent 5d34a96 commit 56fc862
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docs/configuration.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -588,6 +588,11 @@ Another side-effect is that the APM agent does not log the uncaught exception
to stderr by default. Use <<log-uncaught-exceptions, `logUncaughtExceptions: true`>>
to have the agent print the exception to stderr before exiting.

Unhandled rejections (https://nodejs.org/api/process.html#event-unhandledrejection[`unhandledRejection`])
will also be captured if your node process starts with `--unhandled-rejections` mode set to
`strict` or `throw`. If your application run on Node.js 15+ you don't need to explicitly set the mode
since `throw` is the default (https://nodejs.org/api/cli.html#--unhandled-rejectionsmode[reference]).

[[log-uncaught-exceptions]]
==== `logUncaughtExceptions`

Expand Down

0 comments on commit 56fc862

Please sign in to comment.