Include PID in exception logs
This commit is contained in:
1 parent
73295729c8
commit
3fc13317a2
2 files changed
+4
-2
No files matched your search
+2
-1
@@ -131,7 +131,8 @@ function start(service) {
|
|||||||
process.on("uncaughtException", function(err) {
|
process.on("uncaughtException", function(err) {
|
||||||
logger.error({
|
logger.error({
|
||||||
message: "Uncaught exception in master process, exiting",
|
message: "Uncaught exception in master process, exiting",
|
||||||
exception: err
|
exception: err,
|
||||||
|
pid: process.pid
|
||||||
});
|
});
|
||||||
cluster.removeListener("exit", restartWorker);
|
cluster.removeListener("exit", restartWorker);
|
||||||
for (let pid in cluster.workers)
|
for (let pid in cluster.workers)
|
||||||
|
|||||||
+2
-1
@@ -66,7 +66,8 @@ exit = () ->
|
|||||||
process.on('uncaughtException', (err) ->
|
process.on('uncaughtException', (err) ->
|
||||||
logger.error({
|
logger.error({
|
||||||
message: 'Uncaught exception'
|
message: 'Uncaught exception'
|
||||||
exception: err
|
exception: err,
|
||||||
|
pid: process.pid
|
||||||
})
|
})
|
||||||
exit()
|
exit()
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in new issue
Block a user