LsomeYeah commented on code in PR #6472:
URL: https://github.com/apache/paimon/pull/6472#discussion_r2468123558
##########
paimon-core/src/main/java/org/apache/paimon/append/cluster/IncrementalClusterManager.java:
##########
@@ -69,14 +84,35 @@ public IncrementalClusterManager(
checkArgument(
table.bucketMode() == BucketMode.BUCKET_UNAWARE,
"only append unaware-bucket table support incremental
clustering.");
- // drop stats to reduce memory usage
- this.snapshotReader =
-
table.newSnapshotReader().withPartitionFilter(specifiedPartitions).dropStats();
CoreOptions options = table.coreOptions();
checkArgument(
options.clusteringIncrementalEnabled(),
"Only support incremental clustering when '%s' is true.",
CLUSTERING_INCREMENTAL.key());
+
+ this.partitionComputer =
+ new InternalRowPartitionComputer(
+ table.coreOptions().partitionDefaultName(),
+ table.store().partitionType(),
+ table.partitionKeys().toArray(new String[0]),
+ table.coreOptions().legacyPartitionName());
+
+ this.specifiedPartitions = specifiedPartitions;
+
+ // config for history partition auto clustering
+ this.historyPartitionAutoCluster =
options.clusteringHistoryPartitionAutoEnabled();
+ this.partitionIdleTime = options.clusteringPartitionIdleTime();
+ this.historyPartitionLimit = options.clusteringHistoryPartitionLimit();
+
+ if (historyPartitionAutoCluster) {
Review Comment:
I added a `manifestLevelFilter` in `ManifestReader` to filter the manifest
file according to the minLevel value.
For `readPartitionEntries` in history clustering, if the minLevel >
maxLevel/2, we can filter this manifest file.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]