]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: use direct replay test when deciding whether to rebalance.
authorGreg Farnum <gregf@hq.newdream.net>
Wed, 12 Jan 2011 22:54:01 +0000 (14:54 -0800)
committerGreg Farnum <gregory.farnum@dreamhost.com>
Wed, 19 Jan 2011 19:20:09 +0000 (11:20 -0800)
The previous use of standby_for_rank testing was prone to errors
and I think would have ended up causing bugs if it was in the middle
of a standby_replay run when it got a new MDS map pushing
it into regular replay mode.

Signed-off-by: Greg Farnum <gregf@hq.newdream.net>
src/mds/MDS.cc

index 6f3bdf6150d1b7d1cddbecd98413f5123632549e..79372a6a2bc6fda2c342fcd3387378062b8f013d 100644 (file)
@@ -995,7 +995,7 @@ void MDS::handle_mds_map(MMDSMap *m)
        mdcache->migrator->handle_mds_failure_or_stop(*p);
   }
 
-  if (standby_for_rank < 0) //if we're not replaying
+  if (!is_any_replay())
     balancer->try_rebalance();
 
  out: