extract ClientManager from server.js

Make client manager more robust when piping connections.
This commit is contained in:
Roman Shtylman
2017-12-11 21:16:55 -08:00
parent b4a36c78b0
commit 5fb9dbaaa1
8 changed files with 313 additions and 266 deletions

View File

@@ -45,5 +45,14 @@ process.on('SIGTERM', () => {
process.exit();
});
process.on('uncaughtException', (err) => {
log.error(err);
process.exit(1);
});
process.on('unhandledRejection', (reason, promise) => {
log.error(reason);
});
// vim: ft=javascript