Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

emit "master change" for adding / removing workers

  • Loading branch information...
commit da6dba912ec5a5cb6c354585cb6285fac6dc53b0 1 parent 74b4b98
@tj authored
Showing with 2 additions and 0 deletions.
  1. +2 −0  lib/cluster-live.js
View
2  lib/cluster-live.js
@@ -62,9 +62,11 @@ function live(port, host, options) {
switch (msg) {
case 'add-worker':
master.spawn(1);
+ sockets.emit('master change', stripMaster(master));
break;
case 'remove-worker':
master.remove(1);
+ sockets.emit('master change', stripMaster(master));
break;
}
});
Please sign in to comment.
Something went wrong with that request. Please try again.