You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "walterddr (via GitHub)" <gi...@apache.org> on 2023/02/01 22:01:29 UTC

[GitHub] [pinot] walterddr commented on a diff in pull request #10211: [multistage] add singleton instance stage

walterddr commented on code in PR #10211:
URL: https://github.com/apache/pinot/pull/10211#discussion_r1093776745


##########
pinot-query-planner/src/main/java/org/apache/calcite/rel/rules/PinotJoinExchangeNodeInsertRule.java:
##########
@@ -65,7 +65,7 @@ public void onMatch(RelOptRuleCall call) {
 
     if (joinInfo.leftKeys.isEmpty()) {
       // when there's no JOIN key, use broadcast.
-      leftExchange = LogicalExchange.create(leftInput, RelDistributions.SINGLETON);
+      leftExchange = LogicalExchange.create(leftInput, RelDistributions.RANDOM_DISTRIBUTED);
       rightExchange = LogicalExchange.create(rightInput, RelDistributions.BROADCAST_DISTRIBUTED);

Review Comment:
   it is the least restrictive exchange needed --> e.g. if right side has already broadcast the data; left side can be arbitrarily exchange its data to join stage.
   
   - previously we can allow singleton here b/c we want to optimize local-to-local transfer without ser/de or grpc hopping;
   - however with the new singleton stage, we might not be able to apply this optimization thus we relax the exchange to random



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org