@@ -358,7 +358,6 @@ void OSDSingletonState::handle_conf_change(
358358seastar::future<OSDSingletonState::local_cached_map_t >
359359OSDSingletonState::get_local_map (epoch_t e)
360360{
361- // TODO: use LRU cache for managing osdmap, fallback to disk if we have to
362361 if (auto found = osdmaps.find (e); found) {
363362 logger ().debug (" {} osdmap.{} found in cache" , __func__, e);
364363 return seastar::make_ready_future<local_cached_map_t >(std::move (found));
@@ -398,6 +397,9 @@ seastar::future<std::map<epoch_t, bufferlist>> OSDSingletonState::load_map_bls(
398397 logger ().debug (" {} loading maps [{},{}]" ,
399398 __func__, first, last);
400399 ceph_assert (first <= last);
400+ // TODO: take osd_map_max into account
401+ // int max = cct->_conf->osd_map_message_max;
402+ // ssize_t max_bytes = cct->_conf->osd_map_message_max_bytes;
401403 return seastar::map_reduce (boost::make_counting_iterator<epoch_t >(first),
402404 boost::make_counting_iterator<epoch_t >(last + 1 ),
403405 [this ](epoch_t e) {
@@ -750,6 +752,8 @@ seastar::future<> OSDSingletonState::send_incremental_map(
750752 " superblock's oldest map: {}" ,
751753 __func__, first, superblock.get_oldest_map ());
752754 if (first >= superblock.get_oldest_map ()) {
755+ // TODO: osd_map_share_max_epochs
756+ // See OSDService::build_incremental_map_msg
753757 if (first < superblock.cluster_osdmap_trim_lower_bound ) {
754758 logger ().info (" {}: cluster osdmap lower bound: {} "
755759 " > first {}, starting with full map" ,
0 commit comments