Class DeleteOrphanFiles.Builder
java.lang.Object
org.apache.iceberg.flink.maintenance.api.MaintenanceTaskBuilder<DeleteOrphanFiles.Builder>
org.apache.iceberg.flink.maintenance.api.DeleteOrphanFiles.Builder
- Enclosing class:
DeleteOrphanFiles
public static class DeleteOrphanFiles.Builder
extends MaintenanceTaskBuilder<DeleteOrphanFiles.Builder>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondeleteBatchSize
(int newDeleteBatchSize) Size of the batch used to deleting the files.equalAuthorities
(Map<String, String> newEqualAuthorities) Passes authorities that should be considered equal.equalSchemes
(Map<String, String> newEqualSchemes) Passes schemes that should be considered equal.The location to start the recursive listing the candidate files for removal.The files newer than this age will not be removed.planningWorkerPoolSize
(int newPlanningWorkerPoolSize) The worker pool size used for planning the scan of theMetadataTableType.ALL_FILES
table.prefixMismatchMode
(DeleteOrphanFiles.PrefixMismatchMode newPrefixMismatchMode) Action behavior when location prefixes (schemes/authorities) mismatch.usePrefixListing
(boolean newUsePrefixListing) Whether to use prefix listing when listing files from the file system.Methods inherited from class org.apache.iceberg.flink.maintenance.api.MaintenanceTaskBuilder
index, operatorName, parallelism, parallelism, scheduleOnCommitCount, scheduleOnDataFileCount, scheduleOnDataFileSize, scheduleOnEqDeleteFileCount, scheduleOnEqDeleteRecordCount, scheduleOnInterval, scheduleOnPosDeleteFileCount, scheduleOnPosDeleteRecordCount, slotSharingGroup, slotSharingGroup, tableLoader, tableName, taskName, uidSuffix, uidSuffix
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
location
The location to start the recursive listing the candidate files for removal. By default, theTable.location()
is used.- Parameters:
newLocation
- the task will scan- Returns:
- for chained calls
-
usePrefixListing
Whether to use prefix listing when listing files from the file system.- Parameters:
newUsePrefixListing
- true to enable prefix listing, false otherwise- Returns:
- for chained calls
-
prefixMismatchMode
public DeleteOrphanFiles.Builder prefixMismatchMode(DeleteOrphanFiles.PrefixMismatchMode newPrefixMismatchMode) Action behavior when location prefixes (schemes/authorities) mismatch.- Parameters:
newPrefixMismatchMode
- to action when mismatch- Returns:
- for chained calls
-
minAge
The files newer than this age will not be removed.- Parameters:
newMinAge
- of the files to be removed- Returns:
- for chained calls
-
planningWorkerPoolSize
The worker pool size used for planning the scan of theMetadataTableType.ALL_FILES
table. This scan is used for determining the files used by the table.- Parameters:
newPlanningWorkerPoolSize
- for scanning- Returns:
- for chained calls
-
equalSchemes
Passes schemes that should be considered equal.The key may include a comma-separated list of schemes. For instance, Map("s3a,s3,s3n","s3").
- Parameters:
newEqualSchemes
- list of equal schemes- Returns:
- this for method chaining
-
equalAuthorities
Passes authorities that should be considered equal.The key may include a comma-separate list of authorities. For instance, Map("s1name,s2name","servicename").
- Parameters:
newEqualAuthorities
- list of equal authorities- Returns:
- this for method chaining
-
deleteBatchSize
Size of the batch used to deleting the files.- Parameters:
newDeleteBatchSize
- number of batch file- Returns:
- for chained calls
-