diff --git a/lib/server.js b/lib/server.js index 760b2694f..c071cbb46 100644 --- a/lib/server.js +++ b/lib/server.js @@ -389,18 +389,18 @@ class Server extends KarmaEventEmitter { processWrapper.on('SIGTERM', disconnectBrowsers) const reportError = (error) => { - process.emit('infrastructure_error', error) + process.emit(`infrastructure_error: ${error.message || String(error)}` disconnectBrowsers(1) this.log.error(error) } processWrapper.on('unhandledRejection', (error) => { - this.log.error('UnhandledRejection') + this.log.error(`UnhandledRejection: ${error.message || String(error)}`) reportError(error) }) processWrapper.on('uncaughtException', (error) => { - this.log.error('UncaughtException') + this.log.error(`UncaughtException:: ${error.message || String(error)}`) reportError(error) }) }