Add comments about fictitious subcolumns

This commit is contained in:
avogar 2024-07-23 10:27:12 +00:00
parent bc7fd604b7
commit 824506290b
3 changed files with 7 additions and 0 deletions

View File

@ -132,6 +132,7 @@ void MergeTreeDataPartWriterWide::addStreams(
{
assert(!substream_path.empty());
/// Don't create streams for fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;
@ -208,6 +209,7 @@ ISerialization::OutputStreamGetter MergeTreeDataPartWriterWide::createStreamGett
{
return [&, this] (const ISerialization::SubstreamPath & substream_path) -> WriteBuffer *
{
/// Skip fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return nullptr;
@ -373,6 +375,7 @@ StreamsWithMarks MergeTreeDataPartWriterWide::getCurrentMarksForColumn(
min_compress_block_size = settings.min_compress_block_size;
getSerialization(name_and_type.name)->enumerateStreams([&] (const ISerialization::SubstreamPath & substream_path)
{
/// Skip fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;
@ -414,6 +417,7 @@ void MergeTreeDataPartWriterWide::writeSingleGranule(
/// So that instead of the marks pointing to the end of the compressed block, there were marks pointing to the beginning of the next one.
serialization->enumerateStreams([&] (const ISerialization::SubstreamPath & substream_path)
{
/// Skip fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;

View File

@ -213,6 +213,7 @@ void MergeTreeReaderWide::addStreams(
ISerialization::StreamCallback callback = [&] (const ISerialization::SubstreamPath & substream_path)
{
/// Don't create streams for fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;
@ -351,6 +352,7 @@ void MergeTreeReaderWide::prefetchForColumn(
deserializePrefix(serialization, name_and_type, current_task_last_mark, cache, deserialize_states_cache);
auto callback = [&](const ISerialization::SubstreamPath & substream_path)
{
/// Skip fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;

View File

@ -211,6 +211,7 @@ static IMergeTreeDataPart::Checksums checkDataPart(
{
get_serialization(column)->enumerateStreams([&](const ISerialization::SubstreamPath & substream_path)
{
/// Skip fictitious subcolumns that don't store any real data.
if (ISerialization::isFictitiousSubcolumn(substream_path, substream_path.size()))
return;