|
|
|
@ -125,13 +125,7 @@ process.on('message', messageHandler);
|
|
|
|
|
function sendToWorkers(data) {
|
|
|
|
|
let goodWorkers = [];
|
|
|
|
|
workerList.forEach(function (worker) {
|
|
|
|
|
try {
|
|
|
|
|
if (worker.send(data)) {
|
|
|
|
|
goodWorkers.push(worker);
|
|
|
|
|
}
|
|
|
|
|
} catch (e) {
|
|
|
|
|
console.log(threadName + "Worker dead. Not sending new messages.");
|
|
|
|
|
}
|
|
|
|
|
worker.send(data);
|
|
|
|
|
});
|
|
|
|
|
workerList = goodWorkers;
|
|
|
|
|
}
|
|
|
|
@ -783,6 +777,7 @@ if (cluster.isMaster) {
|
|
|
|
|
templateUpdate(false);
|
|
|
|
|
setInterval(function () {
|
|
|
|
|
bannedIPs = [];
|
|
|
|
|
templateUpdate(false);
|
|
|
|
|
}, 60000);
|
|
|
|
|
async.each(global.config.ports, function (portData) {
|
|
|
|
|
if (global.config[portData.portType].enable !== true){
|
|
|
|
|