This commit is contained in:
zhongyuankai 2022-11-15 08:47:51 +08:00
parent ea11d80536
commit 16f697f61d

View File

@ -638,7 +638,8 @@ size_t MergeTreeDataMergerMutator::estimateNeededDiskSpace(const MergeTreeData::
for (const MergeTreeData::DataPartPtr & part : source_parts)
{
/// Exclude expired parts
if (part->ttl_infos.part_max_ttl <= current_time)
time_t part_max_ttl = part->ttl_infos.part_max_ttl;
if (part_max_ttl && part_max_ttl <= current_time)
continue;
res += part->getBytesOnDisk();