diff --git a/pinot-core/src/main/java/org/apache/pinot/core/common/MinionConstants.java b/pinot-core/src/main/java/org/apache/pinot/core/common/MinionConstants.java index 24db1f9ede3c..9fef661075b0 100644 --- a/pinot-core/src/main/java/org/apache/pinot/core/common/MinionConstants.java +++ b/pinot-core/src/main/java/org/apache/pinot/core/common/MinionConstants.java @@ -287,11 +287,6 @@ public static class UpsertCompactMergeTask { */ public static final String OUTPUT_SEGMENT_MAX_SIZE_KEY = "outputSegmentMaxSize"; - /** - * default output segment size - */ - public static final String DEFAULT_OUTPUT_SEGMENT_MAX_SIZE = "200MB"; - /** * default maximum number of segments to process in a single task */ diff --git a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/upsertcompactmerge/UpsertCompactMergeTaskGenerator.java b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/upsertcompactmerge/UpsertCompactMergeTaskGenerator.java index dd7bf283532a..b15bff86980f 100644 --- a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/upsertcompactmerge/UpsertCompactMergeTaskGenerator.java +++ b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/upsertcompactmerge/UpsertCompactMergeTaskGenerator.java @@ -182,7 +182,8 @@ public List generateTasks(List tableConfigs) { Set alreadyMergedSegments = getAlreadyMergedSegments(allSegments); SegmentSelectionResult segmentSelectionResult = - processValidDocIdsMetadata(taskConfigs, candidateSegmentsMap, validDocIdsMetadataList, alreadyMergedSegments); + processValidDocIdsMetadata(tableNameWithType, taskConfigs, candidateSegmentsMap, validDocIdsMetadataList, + alreadyMergedSegments); if (!segmentSelectionResult.getSegmentsForDeletion().isEmpty()) { pinotHelixResourceManager.deleteSegments(tableNameWithType, segmentSelectionResult.getSegmentsForDeletion(), @@ -229,8 +230,8 @@ public List generateTasks(List tableConfigs) { } @VisibleForTesting - public static SegmentSelectionResult processValidDocIdsMetadata(Map taskConfigs, - Map candidateSegmentsMap, + public static SegmentSelectionResult processValidDocIdsMetadata(String tableNameWithType, + Map taskConfigs, Map candidateSegmentsMap, Map> validDocIdsMetadataInfoMap, Set alreadyMergedSegments) { Map> segmentsEligibleForCompactMerge = new HashMap<>(); Set segmentsForDeletion = new HashSet<>(); @@ -245,14 +246,22 @@ public static SegmentSelectionResult processValidDocIdsMetadata(Map