siddharthteotia commented on code in PR #9064:
URL: https://github.com/apache/pinot/pull/9064#discussion_r927886181


##########
pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/MailboxSendOperator.java:
##########
@@ -117,43 +105,40 @@ public String toExplainString() {
 
   @Override
   protected TransferableBlock getNextBlock() {
-    BaseDataBlock dataTable;
+    BaseDataBlock dataBlock;
     TransferableBlock transferableBlock = null;
     boolean isEndOfStream;
-    if (_dataTableBlockBaseOperator != null) {
-      transferableBlock = _dataTableBlockBaseOperator.nextBlock();
-      dataTable = transferableBlock.getDataBlock();
-      isEndOfStream = TransferableBlockUtils.isEndOfStream(transferableBlock);
-    } else {
-      dataTable = _dataTable;
-      isEndOfStream = true;
-    }
+    transferableBlock = _dataTableBlockBaseOperator.nextBlock();
+    dataBlock = transferableBlock.getDataBlock();
+    isEndOfStream = TransferableBlockUtils.isEndOfStream(transferableBlock);
 
     try {
       switch (_exchangeType) {
-        // TODO: random and singleton distribution should've been selected in 
planning phase.
         case SINGLETON:
+          // TODO: singleton or random distribution should've been 
distinguished in planning phase.

Review Comment:
   qq on single vs random --
   
   Assuming `stage 0` is the root stage, the intermediary `stage 1` should be 
having `senders` sending to a single `receiver` in the root stage at all times 
because at the end there has to be a single receiver (ordered or unordered 
etc). If so, then I am not sure why we are currently doing 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-unsubscr...@pinot.apache.org

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


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

Reply via email to