From ce5141ebdd7ac5c8c74de6a8f148c440ed832001 Mon Sep 17 00:00:00 2001 From: obdev Date: Wed, 18 Sep 2024 05:36:54 +0000 Subject: [PATCH] [MDS] adjust snapshot not max defence logic when read TabletStatus --- src/storage/tablet/ob_i_tablet_mds_interface.ipp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/storage/tablet/ob_i_tablet_mds_interface.ipp b/src/storage/tablet/ob_i_tablet_mds_interface.ipp index 28948e2a8..d096120b0 100644 --- a/src/storage/tablet/ob_i_tablet_mds_interface.ipp +++ b/src/storage/tablet/ob_i_tablet_mds_interface.ipp @@ -151,7 +151,9 @@ inline int ObITabletMdsInterface::get_mds_data_from_tablet( int ret = OB_SUCCESS; ObArenaAllocator allocator(ObMemAttr(MTL_ID(), "mds_reader", ObCtxIds::DEFAULT_CTX_ID)); - if (OB_UNLIKELY(!snapshot.is_max())) { + if (!mds::get_multi_version_flag() && + !std::is_same::value && + !snapshot.is_max()) { ret = OB_INVALID_ARGUMENT; MDS_LOG(WARN, "invalid args, snapshot is not max scn", K(ret), K(snapshot)); } else if (CLICK_FAIL((read_data_from_cache_or_mds_sstable(