Permalink
Browse files

Fixing the bad failover bug

  • Loading branch information...
1 parent c012f99 commit 28245d22518d10cea705237bb2dd30963730e696 @sreeix committed Apr 23, 2012
Showing with 4 additions and 2 deletions.
  1. +2 −1 .gitignore
  2. +2 −1 lib/redis_proxy.js
View
@@ -1 +1,2 @@
-dump.rdb
+dump.rdb
+npm-debug.log
View
@@ -59,7 +59,8 @@ RedisProxy.prototype.readyup = function(active){
active.slavenone();
_.each(this.allServers, function (s){
if(!_.isEqual(s, active)){
- s.client.slaveof(active.host, active.port, redis.print);
+ winston.info('Marking '+ s.client.port + ' as slave of '+ active.client.port);
+ s.client.slaveof(active.client.host, active.client.port, redis.print);
}
});
};

0 comments on commit 28245d2

Please sign in to comment.