Skip to content

Commit 8796c8a

Browse files
fix portion kind modification (#7868)
1 parent 7cd8a2c commit 8796c8a

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

ydb/core/tx/columnshard/engines/changes/general_compaction.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,9 @@ void TGeneralCompactColumnEngineChanges::BuildAppendedPortionsByChunks(
141141
shardingActualVersion = shardingActual->GetSnapshotVersion();
142142
}
143143
AppendedPortions = merger.Execute(stats, CheckPoints, resultFiltered, GranuleMeta->GetPathId(), shardingActualVersion);
144+
for (auto&& p : AppendedPortions) {
145+
p.GetPortionConstructor().MutableMeta().UpdateRecordsMeta(NPortion::EProduced::SPLIT_COMPACTED);
146+
}
144147
}
145148

146149
TConclusionStatus TGeneralCompactColumnEngineChanges::DoConstructBlobs(TConstructionContext& context) noexcept {

ydb/core/tx/columnshard/engines/changes/indexation.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,7 @@ TConclusionStatus TInsertColumnEngineChanges::DoConstructBlobs(TConstructionCont
266266
merger.SetOptimizationWritingPackMode(true);
267267
auto localAppended = merger.Execute(stats, itGranule->second, filteredSnapshot, pathId, shardingVersion);
268268
for (auto&& i : localAppended) {
269+
i.GetPortionConstructor().MutableMeta().UpdateRecordsMeta(NPortion::EProduced::INSERTED);
269270
AppendedPortions.emplace_back(std::move(i));
270271
}
271272
}

ydb/core/tx/columnshard/engines/changes/with_appended.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ void TChangesWithAppend::DoWriteIndexOnComplete(NColumnShard::TColumnShard* self
8989
void TChangesWithAppend::DoCompile(TFinalizationContext& context) {
9090
for (auto&& i : AppendedPortions) {
9191
i.GetPortionConstructor().SetPortionId(context.NextPortionId());
92-
i.GetPortionConstructor().MutableMeta().UpdateRecordsMeta(TPortionMeta::EProduced::INSERTED);
9392
}
9493
for (auto& [_, portionInfo] : PortionsToRemove) {
9594
portionInfo.SetRemoveSnapshot(context.GetSnapshot());

0 commit comments

Comments
 (0)