TheR1sing3un commented on code in PR #17996:
URL: https://github.com/apache/hudi/pull/17996#discussion_r2726359539
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/config/HoodieArchivalConfig.java:
##########
@@ -107,6 +107,13 @@ public class HoodieArchivalConfig extends HoodieConfig {
.defaultValue(1000L * 1024 * 1024)
.markAdvanced()
.withDocumentation("Max size (in bytes) for each archived timeline
file.");
+
+ public static final ConfigProperty<Integer>
TIMELINE_MANIFEST_VERSION_RETAINED = ConfigProperty
+ .key("hoodie.timeline.manifest.version.retained")
Review Comment:
> hoodie.timeline.manifest.retained.versions
done
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/client/timeline/versioning/v2/LSMTimelineWriter.java:
##########
@@ -329,9 +329,11 @@ public void compactFiles(List<String> candidateFiles,
String compactedFileName)
* @param context HoodieEngineContext used for parallelize to delete
obsolete files if necessary.
*/
public void clean(HoodieEngineContext context, int compactedVersions) throws
IOException {
- // if there are more than 3 version of snapshots, clean the oldest files.
+ int versionRetained = config.getTimelineManifestVersionRetained();
+ log.info("Starting cleaning obsolete files, retaining last ({} + {})
manifest versions.", versionRetained, compactedVersions);
Review Comment:
> retaining last -> retaining latest
done
--
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]