English 中文(简体)
Node.js: A. 总组的控制
原标题:node.js: Control from the master cluster

Is it possible to turn on/off redis subscribe dynamically from the master cluster? The reason I ask is that I just want one cluster subscribed at a time, but in case that cluster dies I need to get another one to subscribe.

从根本上说,主组是否能够通过一纸pi向幸运的集群发出信息?

最佳回答

在主人中,你可以轻松地向集群发出信息,而你只是要挽救因“k()”电话而产生的工人物体。

var cluster = require("cluster");
worker = cluster.fork();
worker.on("message,function(msg){
  console.log("Master says:" + msg);
});
worker.send({message: hello });
问题回答

暂无回答




相关问题
Assets Management in a clustered environment

I have a content management system running on a web server, that among others allows the user to upload assets like images, files, etc to the server. The problem i have is that there will be 2 ...

Condor, Sun Grid Engine, or something else?

I m trying to work out whether we should try out Condor or Sun Grid Engine at work (or possibly something else). We often have lots of unused WinXp workstations. The hope is that we could use wake-...

Caching in a clustered environment

Caching your data in your application code is generally a good idea for many reasons. We have being doing this for quiet some time in our shared environment which includes ColdFusion, .NET, and PHP. ...

Programmatically detect Windows cluster configuration?

Does anyone know how to programatically detect that a Windows server is part of a cluster? Further, is it possible to detect that the server is the active or passive node? [Edit] And detect it from ...

热门标签