[Error] Express app crashed
WEB 2023. 5. 9. 11:12Environment :
AWS, Docker, Nodejs express, mariadb
When Error occured :
Do nothing(no transaction or querry) for many hours between express and mariadb
Error Code :
events.js:352
throw er; // Unhandled 'error' event
^
Error: read ECONNRESET
at TCP.onStreamRead (internal/stream_base_commons.js:209:20)
Emitted 'error' event on Connection instance at:
at Connection._handleProtocolError (/source/node_modules/mysql/lib/Connectio n.js:423:8)
at Protocol.emit (events.js:375:28)
at Protocol._delegateError (/source/node_modules/mysql/lib/protocol/Protocol .js:398:10)
at Protocol.handleNetworkError (/source/node_modules/mysql/lib/protocol/Prot ocol.js:371:10)
at Connection._handleNetworkError (/source/node_modules/mysql/lib/Connection .js:418:18)
at Socket.emit (events.js:375: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
}
[nodemon] app crashed - waiting for file changes before starting...
Search:
https://engineering-skcc.github.io/cloud/tomcat/apache/performancetest/MySqlDBWaitTimeOut/
Guess :
mysql disconnects in configured time.
Solution:
using DBCP and set testWhileIdle and validationQuery
but I didn't use any DBCP tools. Maybe use small query can be solution.
'WEB' 카테고리의 다른 글
[Laravel] Laravel + Bitnami wamp 7.3.29 (0) | 2021.08.06 |
---|---|
[Docker] Solved Error : Cannot enable Hyper-V service (0) | 2020.11.09 |