diff --git a/src/storage/blocksstable/ob_shared_macro_block_manager.cpp b/src/storage/blocksstable/ob_shared_macro_block_manager.cpp index e44db64f4..bc21b525c 100644 --- a/src/storage/blocksstable/ob_shared_macro_block_manager.cpp +++ b/src/storage/blocksstable/ob_shared_macro_block_manager.cpp @@ -440,10 +440,11 @@ int ObSharedMacroBlockMgr::defragment() rewrite_cnt, *sstable_index_builder, *index_block_rebuilder))) { - LOG_WARN("fail to update tablet", K(ret), K(tablet_handle), K(macro_ids)); - } - if (OB_UNLIKELY(OB_EAGAIN == ret)) { - ret = OB_SUCCESS; + if (OB_UNLIKELY(OB_EAGAIN != ret)) { + LOG_WARN("fail to update tablet", K(ret), K(tablet_handle), K(macro_ids)); + } else { + ret = OB_SUCCESS; + } } } } @@ -464,8 +465,12 @@ int ObSharedMacroBlockMgr::defragment() index_block_rebuilder = nullptr; } - if (OB_FAIL(ret) && REACH_COUNT_INTERVAL(FAILURE_COUNT_INTERVAL)) { - LOG_ERROR("defragmentation can't be finished, something is wrong", K(ret), K(macro_ids)); + if (OB_FAIL(ret)) { + if (REACH_COUNT_INTERVAL(FAILURE_COUNT_INTERVAL)) { + LOG_ERROR("defragmentation failed 10 times, something is wrong", K(ret), K(macro_ids)); + } else { + LOG_WARN("fail to finish defragmentation", K(ret), K(macro_ids)); + } } return ret; diff --git a/src/storage/tablet/ob_tablet.cpp b/src/storage/tablet/ob_tablet.cpp index c9e13624b..136a35c1c 100644 --- a/src/storage/tablet/ob_tablet.cpp +++ b/src/storage/tablet/ob_tablet.cpp @@ -1232,7 +1232,7 @@ int ObTablet::get_sstables_size(int64_t &used_size, const bool ignore_shared_blo } } if (OB_SUCC(ret) && tablet_meta_.has_next_tablet_ && OB_FAIL( - next_tablet_guard_.get_obj()->get_sstables_size(used_size, true /*ignore shared block*/))) { + next_tablet_guard_.get_obj()->get_sstables_size(used_size, ignore_shared_block /*whether ignore shared block*/))) { LOG_WARN("failed to get size of tablets on the list", K(ret), K(used_size)); } }