Skip to content

Commit 4a674e5

Browse files
kyligence-gitkyligence-gitbaibaichen
authored
[GLUTEN-1632][CH]Daily Update Clickhouse Version (20240705) (#6338)
* [GLUTEN-1632][CH]Daily Update Clickhouse Version (20240705) * Fix build due to ClickHouse/ClickHouse#61601 --------- Co-authored-by: kyligence-git <gluten@kyligence.io> Co-authored-by: Chang Chen <baibaichen@gmail.com>
1 parent f8e6b75 commit 4a674e5

6 files changed

Lines changed: 13 additions & 13 deletions

File tree

cpp-ch/clickhouse.version

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
CH_ORG=Kyligence
2-
CH_BRANCH=rebase_ch/20240704
3-
CH_COMMIT=f617655ccea
2+
CH_BRANCH=rebase_ch/20240705
3+
CH_COMMIT=531a87ed802
44

cpp-ch/local-engine/Operator/DefaultHashAggregateResult.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,18 +116,18 @@ class DefaultHashAggrgateResultTransform : public DB::IProcessor
116116
has_input = true;
117117
output_chunk = DB::Chunk(result_cols, 1);
118118
auto info = std::make_shared<DB::AggregatedChunkInfo>();
119-
output_chunk.setChunkInfo(info);
119+
output_chunk.getChunkInfos().add(std::move(info));
120120
return Status::Ready;
121121
}
122122

123123
input.setNeeded();
124124
if (input.hasData())
125125
{
126126
output_chunk = input.pull(true);
127-
if (!output_chunk.hasChunkInfo())
127+
if (output_chunk.getChunkInfos().empty())
128128
{
129129
auto info = std::make_shared<DB::AggregatedChunkInfo>();
130-
output_chunk.setChunkInfo(info);
130+
output_chunk.getChunkInfos().add(std::move(info));
131131
}
132132
has_input = true;
133133
return Status::Ready;

cpp-ch/local-engine/Storages/Mergetree/SparkMergeTreeWriter.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,12 +121,11 @@ void SparkMergeTreeWriter::write(const DB::Block & block)
121121
checkAndMerge();
122122
}
123123

124-
bool SparkMergeTreeWriter::chunkToPart(Chunk && chunk)
124+
bool SparkMergeTreeWriter::chunkToPart(Chunk && plan_chunk)
125125
{
126-
if (chunk.hasChunkInfo())
126+
if (Chunk result_chunk = DB::Squashing::squash(std::move(plan_chunk)))
127127
{
128-
Chunk squash_chunk = DB::Squashing::squash(std::move(chunk));
129-
Block result = header.cloneWithColumns(squash_chunk.getColumns());
128+
auto result = squashing->getHeader().cloneWithColumns(result_chunk.detachColumns());
130129
return blockToPart(result);
131130
}
132131
return false;

cpp-ch/local-engine/Storages/Mergetree/SparkMergeTreeWriter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ class SparkMergeTreeWriter
7777
void saveMetadata();
7878
void commitPartToRemoteStorageIfNeeded();
7979
void finalizeMerge();
80-
bool chunkToPart(Chunk && chunk);
80+
bool chunkToPart(Chunk && plan_chunk);
8181
bool blockToPart(Block & block);
8282
bool useLocalStorage() const;
8383

cpp-ch/local-engine/Storages/SourceFromJavaIter.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,13 +109,13 @@ DB::Chunk SourceFromJavaIter::generate()
109109
auto info = std::make_shared<DB::AggregatedChunkInfo>();
110110
info->is_overflows = data->info.is_overflows;
111111
info->bucket_num = data->info.bucket_num;
112-
result.setChunkInfo(info);
112+
result.getChunkInfos().add(std::move(info));
113113
}
114114
else
115115
{
116116
result = BlockUtil::buildRowCountChunk(rows);
117117
auto info = std::make_shared<DB::AggregatedChunkInfo>();
118-
result.setChunkInfo(info);
118+
result.getChunkInfos().add(std::move(info));
119119
}
120120
}
121121
return result;

cpp-ch/local-engine/tests/gtest_parser.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,8 @@ TEST(LocalExecutor, StorageObjectStorageSink)
101101

102102
/// 2. Create Chunk
103103
/// 3. comsume
104-
sink.consume(testChunk());
104+
Chunk data = testChunk();
105+
sink.consume(data);
105106
sink.onFinish();
106107
}
107108

0 commit comments

Comments
 (0)