node package manager


A small cluster module with plugin system


npm install clustering
var clustering = require('clustering');
if(clustering.side == 'master')
if(clustering.side == 'worker')

And that will create a cluster running yourServer.

You can also use a plugin EG. use( (watches all files that are loaded)

  • use(plugin(Cluster)) => Use a plugin (execute it passing in the cluster)
  • reload(full = false) => Reload the workers, if full is true then also reload the master
  • kill(signal = 'SIGKILL') => Killall the workers with signal
  • side => 'master' if it's the master, 'worker' if it's a worker
  • watch(full = true) => Automatically reload the cluster
    • full => Whether or not to to a full restart