fix meta merge 4016

This commit is contained in:
Fengjingkun
2023-12-19 00:12:57 +00:00
committed by ob-robot
parent 27e485c0ff
commit 92f12e8d4a
2 changed files with 4 additions and 2 deletions

View File

@ -455,6 +455,7 @@ int ObMediumCompactionScheduleFunc::check_frequency(
const int64_t time_interval = (current_time - max_reserved_snapshot) / 2;
const int64_t last_major_snapshot_version = tablet->get_last_major_snapshot_version();
if (0 >= last_major_snapshot_version) {
ret = OB_ERR_UNEXPECTED;
LOG_WARN("major sstable should not be empty", K(ret), K(last_major_snapshot_version));
} else if (last_major_snapshot_version + time_interval > medium_snapshot) {
ret = OB_NO_NEED_MERGE;