gortiz commented on code in PR #14495:
URL: https://github.com/apache/pinot/pull/14495#discussion_r1850602515
##########
pinot-query-planner/src/main/java/org/apache/pinot/query/planner/plannode/MailboxSendNode.java:
##########
@@ -50,8 +53,42 @@ public MailboxSendNode(int stageId, DataSchema dataSchema,
List<PlanNode> inputs
_sort = sort;
}
+ public MailboxSendNode(int stageId, DataSchema dataSchema, List<PlanNode>
inputs,
+ int receiverStage, PinotRelExchangeType exchangeType,
+ RelDistribution.Type distributionType, @Nullable List<Integer> keys,
boolean prePartitioned,
+ @Nullable List<RelFieldCollation> collations, boolean sort) {
+ this(stageId, dataSchema, inputs, toBitSet(receiverStage), exchangeType,
distributionType, keys, prePartitioned,
+ collations, sort);
+ }
+
+ private static BitSet toBitSet(int receiverStage) {
+ BitSet bitSet = new BitSet(receiverStage + 1);
+ bitSet.set(receiverStage);
+ return bitSet;
+ }
+
+ public MailboxSendNode(int stageId, DataSchema dataSchema, List<PlanNode>
inputs,
+ PinotRelExchangeType exchangeType, RelDistribution.Type
distributionType, @Nullable List<Integer> keys,
+ boolean prePartitioned, @Nullable List<RelFieldCollation> collations,
boolean sort) {
+ this(stageId, dataSchema, inputs, null, exchangeType, distributionType,
keys, prePartitioned, collations, sort);
+ }
+
+ public BitSet getReceiverStages() {
+ Preconditions.checkState(!_receiverStages.isEmpty(), "Receivers not set");
+ return (BitSet) _receiverStages.clone();
+ }
Review Comment:
In my next push I'll remove this method and substitute it with a more
specific one that will be easier to use and won't be affected by this undefined
external mutability problem
--
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]