diff --git a/server/src/server.js b/server/src/server.js index cd29bcb..21df186 100644 --- a/server/src/server.js +++ b/server/src/server.js @@ -127,6 +127,12 @@ export class SitespeedioServer { await setupResultQueue(); // Tell the world that we are starting await publish('server', 'start'); + + process.on('uncaughtException', error => { + // ioredis configuration is tricky to get right + // this can spam the log but at least we catch everything + logger.error('Uncaught Exception thrown:', error); + }); } async stop() { diff --git a/testrunner/src/sitespeedio-testrunner.js b/testrunner/src/sitespeedio-testrunner.js index 923f795..0ab25d0 100644 --- a/testrunner/src/sitespeedio-testrunner.js +++ b/testrunner/src/sitespeedio-testrunner.js @@ -66,6 +66,12 @@ export class SitespeedioTestRunner { } await queueHandler.start(); + + process.on('uncaughtException', error => { + // ioredis configuration is tricky to get right + // this can spam the log but at least we catch everything + logger.error('Uncaught Exception thrown:', error); + }); } async stop() {