【发布时间】:2021-11-19 14:00:26
【问题描述】:
NodeJS Express 应用程序在一段时间后崩溃。
我开始使用npm start 将启动脚本作为
start: "node app.js"
错误
at Socket.emit (events.js:400:28)
at emitErrorNT (internal/streams/destroy.js:106:8)
at emitErrorCloseNT (internal/streams/destroy.js:74:3)
at processTicksAndRejections (internal/process/task_queues.js:82:21) {
errno: -104,
code: 'ECONNRESET',
syscall: 'read',
fatal: true
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! xxx@1.0.0 start: `node app.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the xxx@1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
当服务器启动几个小时时会发生这种情况。我想保持它直到我强制停止。
我也试过 nodemon app.js
【问题讨论】:
-
可能与github.com/nodejs/node/issues/27916有关。最好分享一些代码以便能够重现该问题。
标签: node.js express npm server