Skip to content

Commit

Permalink
Merge pull request ceph#4702 from tchaikov/wip-fix-11590
Browse files Browse the repository at this point in the history
mon: always reply mdsbeacon

Reviewed-by: Joao Eduardo Luis <[email protected]>
Reviewed-by: Greg Farnum <[email protected]>
  • Loading branch information
gregsfortytwo committed Jun 5, 2015
2 parents 5a3da7b + b3555e9 commit 5e99022
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/mon/MDSMonitor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ bool MDSMonitor::preprocess_beacon(MMDSBeacon *m)
goto out;
}
// is there a state change here?
if (info.state != state) {
if (info.state != state) {
// legal state change?
if ((info.state == MDSMap::STATE_STANDBY ||
info.state == MDSMap::STATE_STANDBY_REPLAY ||
Expand Down Expand Up @@ -639,8 +639,14 @@ void MDSMonitor::_updated(MMDSBeacon *m)
if (m->get_state() == MDSMap::STATE_STOPPED) {
// send the map manually (they're out of the map, so they won't get it automatic)
mon->send_reply(m, new MMDSMap(mon->monmap->fsid, &mdsmap));
} else {
mon->send_reply(m, new MMDSBeacon(mon->monmap->fsid,
m->get_global_id(),
m->get_name(),
mdsmap.get_epoch(),
m->get_state(),
m->get_seq()));
}

m->put();
}

Expand Down

0 comments on commit 5e99022

Please sign in to comment.