Command you ran: nodemon --signal SIGHUP src/server.js
Expected behaviour
My Nodejs application leverages cluster child processes. I added this block of code as suggested by the docs:
if (cluster.isMaster) {
process.on("SIGHUP", function () {
for (const worker of Object.values(cluster.workers)) {
worker.process.kill("SIGTERM");
}
});
} else {
process.on("SIGHUP", function() {})
}
When I save a js file, my child processes do get restarted and the VS Code debugger is able to reconnect to them so I can keep debugging the application, which is great. However, my terminal keeps getting spammed:
[nodemon] still waiting for 6 sub-processes to finish...
Am I missing anything? I mean, processes are restarting with the code changes, which is the main goal, but the logs suggest that I'm missing something. What's nodemon waiting for? Should the subprocesses send anything back to nodemon?
Actual behaviour
[nodemon] still waiting for 6 sub-processes to finish... logs
Steps to reproduce
If applicable, please append the --dump flag on your command and include the output here ensuring to remove any sensitive/personal details or tokens.
nodemon -v
: 3.1.7Expected behaviour
My Nodejs application leverages cluster child processes. I added this block of code as suggested by the docs:
When I save a js file, my child processes do get restarted and the VS Code debugger is able to reconnect to them so I can keep debugging the application, which is great. However, my terminal keeps getting spammed:
[nodemon] still waiting for 6 sub-processes to finish...
Am I missing anything? I mean, processes are restarting with the code changes, which is the main goal, but the logs suggest that I'm missing something. What's nodemon waiting for? Should the subprocesses send anything back to nodemon?
Actual behaviour
[nodemon] still waiting for 6 sub-processes to finish...
logsSteps to reproduce
If applicable, please append the
--dump
flag on your command and include the output here ensuring to remove any sensitive/personal details or tokens.