From cf977ce605c38fc0c4198de4e3b48612fca84ba4 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 21 May 2013 15:41:46 -0700 Subject: [PATCH] osd/OSDMap: new_hb_up -> new_hb_back_up Signed-off-by: Sage Weil --- src/mon/OSDMonitor.cc | 4 ++-- src/osd/OSDMap.cc | 10 +++++----- src/osd/OSDMap.h | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/mon/OSDMonitor.cc b/src/mon/OSDMonitor.cc index aa9eff2819b24..ec89c24a5c78c 100644 --- a/src/mon/OSDMonitor.cc +++ b/src/mon/OSDMonitor.cc @@ -249,7 +249,7 @@ bool OSDMonitor::thrash() pending_inc.new_state[o] = CEPH_OSD_UP; pending_inc.new_up_client[o] = entity_addr_t(); pending_inc.new_up_cluster[o] = entity_addr_t(); - pending_inc.new_hb_up[o] = entity_addr_t(); + pending_inc.new_hb_back_up[o] = entity_addr_t(); pending_inc.new_weight[o] = CEPH_OSD_IN; thrash_last_up_osd = o; } @@ -1127,7 +1127,7 @@ bool OSDMonitor::prepare_boot(MOSDBoot *m) pending_inc.new_up_client[from] = m->get_orig_source_addr(); if (!m->cluster_addr.is_blank_ip()) pending_inc.new_up_cluster[from] = m->cluster_addr; - pending_inc.new_hb_up[from] = m->hb_addr; + pending_inc.new_hb_back_up[from] = m->hb_addr; // mark in? if ((g_conf->mon_osd_auto_mark_auto_out_in && (oldstate & CEPH_OSD_AUTOOUT)) || diff --git a/src/osd/OSDMap.cc b/src/osd/OSDMap.cc index e5fc4144e5bae..a3b5fed259ad9 100644 --- a/src/osd/OSDMap.cc +++ b/src/osd/OSDMap.cc @@ -317,7 +317,7 @@ void OSDMap::Incremental::encode(bufferlist& bl, uint64_t features) const // extended __u16 ev = 9; ::encode(ev, bl); - ::encode(new_hb_up, bl); + ::encode(new_hb_back_up, bl); ::encode(new_up_thru, bl); ::encode(new_last_clean_interval, bl); ::encode(new_lost, bl); @@ -402,7 +402,7 @@ void OSDMap::Incremental::decode(bufferlist::iterator &p) __u16 ev = 0; if (v >= 5) ::decode(ev, p); - ::decode(new_hb_up, p); + ::decode(new_hb_back_up, p); if (v < 5) ::decode(new_pool_names, p); ::decode(new_up_thru, p); @@ -469,7 +469,7 @@ void OSDMap::Incremental::dump(Formatter *f) const f->dump_int("osd", p->first); f->dump_stream("public_addr") << p->second; f->dump_stream("cluster_addr") << new_up_cluster.find(p->first)->second; - f->dump_stream("heartbeat_addr") << new_hb_up.find(p->first)->second; + f->dump_stream("heartbeat_addr") << new_hb_back_up.find(p->first)->second; f->close_section(); } f->close_section(); @@ -869,11 +869,11 @@ int OSDMap::apply_incremental(const Incremental &inc) ++i) { osd_state[i->first] |= CEPH_OSD_EXISTS | CEPH_OSD_UP; osd_addrs->client_addr[i->first].reset(new entity_addr_t(i->second)); - if (inc.new_hb_up.empty()) + if (inc.new_hb_back_up.empty()) osd_addrs->hb_addr[i->first].reset(new entity_addr_t(i->second)); //this is a backward-compatibility hack else osd_addrs->hb_addr[i->first].reset( - new entity_addr_t(inc.new_hb_up.find(i->first)->second)); + new entity_addr_t(inc.new_hb_back_up.find(i->first)->second)); osd_info[i->first].up_from = epoch; } for (map::const_iterator i = inc.new_up_cluster.begin(); diff --git a/src/osd/OSDMap.h b/src/osd/OSDMap.h index e961b11360d78..8038dfd32eabc 100644 --- a/src/osd/OSDMap.h +++ b/src/osd/OSDMap.h @@ -139,7 +139,7 @@ public: map new_blacklist; vector old_blacklist; - map new_hb_up; + map new_hb_back_up; string cluster_snapshot; -- 2.39.5