You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[^nodejs_uncaught]: [Warning: Using `'uncaughtException'` correctly](https://nodejs.org/docs/latest-v22.x/api/process.html#process_warning_using_uncaughtexception_correctly)
54
+
55
+
> Attempting to resume normally after an uncaught exception can be similar to pulling out the power cord when upgrading a computer. Nine out of ten times, nothing happens. But the tenth time, the system becomes corrupted.
56
+
>
57
+
> The correct use of `'uncaughtException'` is to perform synchronous cleanup of allocated resources (e.g. file descriptors, handles, etc) before shutting down the process. **It is not safe to resume normal operation after `'uncaughtException'`**.
> Some exceptions are *unrecoverable* at the JavaScript layer. Such exceptions will *always* cause the Node.js process to crash. Examples include `assert()` checks or `abort()` calls in the C++ layer.
62
+
63
+
[^exceptions_vs_errors]: [Exceptions vs. errors](https://nodejs.org/docs/latest-v22.x/api/errors.html#exceptions-vs-errors)
后来我去看了对应版本 Node.js HTTP 模块所有相关的 Changelog,找到了疑似的故障源头:[Reusing HTTP connection lead to no destroy triggered](https://github.com/nodejs/node/issues/19859)
> A cryptographic vulnerability exists in Node.js <19.2.0, <18.14.1, <16.19.1, <14.21.3 that in some cases did does not clear the OpenSSL error stack after operations that may set it. This may lead to false positive errors during subsequent cryptographic operations that happen to be on the same thread. This in turn could be used to cause a denial of service.
0 commit comments