Add a comment for lack of fsync in MergedBlockOutputStream::finalizePartOnDisk()

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
This commit is contained in:
Azat Khuzhin 2022-12-30 22:24:58 +01:00
parent 9fb6004c92
commit e7bf2cc959

View File

@ -200,7 +200,9 @@ MergedBlockOutputStream::WrittenFiles MergedBlockOutputStream::finalizePartOnDis
const MergeTreeMutableDataPartPtr & new_part, const MergeTreeMutableDataPartPtr & new_part,
MergeTreeData::DataPart::Checksums & checksums) MergeTreeData::DataPart::Checksums & checksums)
{ {
/// NOTE: You do not need to call fsync here, since it will be called later for the all written_files.
WrittenFiles written_files; WrittenFiles written_files;
if (new_part->isProjectionPart()) if (new_part->isProjectionPart())
{ {
if (storage.format_version >= MERGE_TREE_DATA_MIN_FORMAT_VERSION_WITH_CUSTOM_PARTITIONING || isCompactPart(new_part)) if (storage.format_version >= MERGE_TREE_DATA_MIN_FORMAT_VERSION_WITH_CUSTOM_PARTITIONING || isCompactPart(new_part))