xiangfu0 commented on code in PR #19537:
URL: https://github.com/apache/pinot/pull/19537#discussion_r4240980926


##########
pinot-query-planner/src/main/java/org/apache/pinot/query/routing/WorkerManager.java:
##########
@@ -1169,9 +1187,17 @@ private void 
setSegmentsForReplicatedLeafFragment(DispatchablePlanMetadata metad
       }
     }
 
-    // TODO: Support unavailable segments and optional segments for replicated 
leaf stage
     metadata.setReplicatedSegments(segmentsMap);

Review Comment:
   **[MINOR] The removed TODO promised "unavailable segments and optional 
segments for replicated leaf stage", but only the unavailable-segments half is 
implemented.** `setReplicatedSegments(segmentsMap)` still carries only required 
segments — optional segments are dropped for the replicated leaf path, and with 
the TODO deleted there is no longer any marker that this remains unsupported. 
Either implement optional segments here too or keep (narrow) the TODO.



##########
pinot-query-planner/src/main/java/org/apache/pinot/query/routing/WorkerManager.java:
##########
@@ -1334,6 +1364,8 @@ private static void 
assignTableSegmentsToWorkers(LogicalTableRouteInfo logicalTa
     Map<Integer, QueryServerInstance> workerIdToServerInstanceMap = 
Maps.newHashMapWithExpectedSize(numWorkers);
     Map<Integer, Map<String, List<String>>> workerIdToLogicalTableSegmentsMap =
         Maps.newHashMapWithExpectedSize(numWorkers);
+    Map<Integer, Map<String, List<String>>> 
workerIdTOptionalLogicalTableSegmentsMap =

Review Comment:
   **[MINOR] Typo in identifier: `workerIdTOptionalLogicalTableSegmentsMap`** — 
missing the "o" in "To" (`workerIdToOptional...`). Also in the new tests, the 
TestNG `assertEquals(List.of("unavailableSeg"), actual)` calls pass arguments 
in (expected, actual) order, but TestNG's signature is `assertEquals(actual, 
expected)` — failure messages will be inverted.



##########
pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/blocks/SerializedDataBlock.java:
##########
@@ -24,6 +24,7 @@
 import org.apache.pinot.common.utils.DataSchema;
 import org.apache.pinot.core.util.DataBlockExtractUtils;
 
+

Review Comment:
   **[MINOR] Unrelated whitespace-only change.** This file's only change in the 
PR is an added blank line — please drop it to keep the diff scoped to the 
optional-segments work.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to