summaryrefslogtreecommitdiffstats
path: root/src/mds/MDSMap.h
diff options
context:
space:
mode:
authorYan, Zheng <zyan@redhat.com>2017-07-20 12:04:47 +0200
committerYan, Zheng <zyan@redhat.com>2017-11-09 04:17:08 +0100
commit82348673098a3a8176edb878a559eaa61068d9fd (patch)
treee43f5deea44d4930f28a8d771d3d13c1e355e803 /src/mds/MDSMap.h
parentmds: properly distinguish snaptable TABLE_OP_CREATE from TABLE_OP_UPDATE (diff)
downloadceph-82348673098a3a8176edb878a559eaa61068d9fd.tar.xz
ceph-82348673098a3a8176edb878a559eaa61068d9fd.zip
mds: introduce MDSMap::get_mds_set_lower_bound()
return mds set whose states are larger than or equal to a given state Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Diffstat (limited to 'src/mds/MDSMap.h')
-rw-r--r--src/mds/MDSMap.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/mds/MDSMap.h b/src/mds/MDSMap.h
index 143e4901293..68b00c86746 100644
--- a/src/mds/MDSMap.h
+++ b/src/mds/MDSMap.h
@@ -451,12 +451,11 @@ public:
s.insert(p.second.rank);
}
- void
- get_clientreplay_or_active_or_stopping_mds_set(std::set<mds_rank_t>& s) const {
+ void get_mds_set_lower_bound(std::set<mds_rank_t>& s, DaemonState first) const {
for (std::map<mds_gid_t, mds_info_t>::const_iterator p = mds_info.begin();
p != mds_info.end();
++p)
- if (p->second.state >= STATE_CLIENTREPLAY && p->second.state <= STATE_STOPPING)
+ if (p->second.state >= first && p->second.state <= STATE_STOPPING)
s.insert(p->second.rank);
}
void get_mds_set(std::set<mds_rank_t>& s, DaemonState state) const {