From: Matan Breizman Date: Wed, 1 Feb 2023 09:32:53 +0000 (+0000) Subject: crimson/osd: Rename MOSDMap::oldest_map users X-Git-Tag: v16.2.14~69^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4fa54f68d2807ec88bc26608d50f4b2cdaa88821;p=ceph.git crimson/osd: Rename MOSDMap::oldest_map users Note: this commit was manually fixed (crimson only) Signed-off-by: Matan Breizman (cherry picked from commit 3f92107d99f4ee6a521e994728418ce7cffd2d95) --- diff --git a/src/crimson/osd/osd.cc b/src/crimson/osd/osd.cc index 71e44d7846d..de1e31a150d 100644 --- a/src/crimson/osd/osd.cc +++ b/src/crimson/osd/osd.cc @@ -496,6 +496,8 @@ void OSD::dump_status(Formatter* f) const f->dump_unsigned("whoami", superblock.whoami); f->dump_string("state", state.to_string()); f->dump_unsigned("oldest_map", superblock.oldest_map); + f->dump_unsigned("cluster_osdmap_trim_lower_bound", + superblock.cluster_osdmap_trim_lower_bound); f->dump_unsigned("newest_map", superblock.newest_map); f->dump_unsigned("num_pgs", pg_map.get_pgs().size()); } @@ -969,7 +971,8 @@ seastar::future<> OSD::handle_osd_map(crimson::net::ConnectionRef conn, const auto first = m->get_first(); const auto last = m->get_last(); logger().info("handle_osd_map epochs [{}..{}], i have {}, src has [{}..{}]", - first, last, superblock.newest_map, m->oldest_map, m->newest_map); + first, last, superblock.newest_map, + m->cluster_osdmap_trim_lower_bound, m->newest_map); // make sure there is something new, here, before we bother flushing // the queues and such if (last <= superblock.newest_map) { @@ -981,15 +984,16 @@ seastar::future<> OSD::handle_osd_map(crimson::net::ConnectionRef conn, if (first > start) { logger().info("handle_osd_map message skips epochs {}..{}", start, first - 1); - if (m->oldest_map <= start) { + if (m->cluster_osdmap_trim_lower_bound <= start) { return shard_services.osdmap_subscribe(start, false); } // always try to get the full range of maps--as many as we can. this // 1- is good to have // 2- is at present the only way to ensure that we get a *full* map as // the first map! - if (m->oldest_map < first) { - return shard_services.osdmap_subscribe(m->oldest_map - 1, true); + if (m->cluster_osdmap_trim_lower_bound < first) { + return shard_services.osdmap_subscribe( + m->cluster_osdmap_trim_lower_bound - 1, true); } skip_maps = true; start = first; @@ -1077,7 +1081,8 @@ seastar::future<> OSD::committed_osd_maps(version_t first, logger().info("osd.{}: now preboot", whoami); if (m->get_source().is_mon()) { - return _preboot(m->oldest_map, m->newest_map); + return _preboot( + m->cluster_osdmap_trim_lower_bound, m->newest_map); } else { logger().info("osd.{}: start_boot", whoami); return start_boot(); @@ -1108,7 +1113,7 @@ seastar::future<> OSD::send_incremental_map(crimson::net::ConnectionRef conn, .then([this, conn, first](auto&& bls) { auto m = make_message(monc->get_fsid(), osdmap->get_encoding_features()); - m->oldest_map = first; + m->cluster_osdmap_trim_lower_bound = first; m->newest_map = superblock.newest_map; m->maps = std::move(bls); return conn->send(m); @@ -1118,7 +1123,7 @@ seastar::future<> OSD::send_incremental_map(crimson::net::ConnectionRef conn, .then([this, conn](auto&& bl) mutable { auto m = make_message(monc->get_fsid(), osdmap->get_encoding_features()); - m->oldest_map = superblock.oldest_map; + m->cluster_osdmap_trim_lower_bound = superblock.oldest_map; m->newest_map = superblock.newest_map; m->maps.emplace(osdmap->get_epoch(), std::move(bl)); return conn->send(m);