richardstartin commented on code in PR #8523: URL: https://github.com/apache/pinot/pull/8523#discussion_r850184819
########## pinot-core/src/main/java/org/apache/pinot/core/plan/CombinePlanNode.java: ########## @@ -185,4 +136,84 @@ public List<Operator> callJob() { return new DistinctCombineOperator(operators, _queryContext, _executorService); } } + + private List<Operator> getOperatorsSingleThreaded() { + List<Operator> operators = new ArrayList<>(_planNodes.size()); + for (PlanNode planNode : _planNodes) { + operators.add(planNode.run()); + } + return operators; + } + + private List<Operator> getOperatorsMultiThreaded(int numThreads) { Review Comment: this is a little confusing. There is an active scope at the point the thread pool is submitted to, which will be migrated into the thread pool and used as the parent of any traced tasks which take place within the thread pool. We want to record that the current scope delegated to N threads, so we should call `setNumTasks(numThreads)` to record that, and to be consistent with `BaseCombineOperator`. I don't think we need to trace the tasks completed within the thread pool, because they're not expected to take very long, and they just represent an arbitrary partition of the planning work. What's important is to record that we blocked a thread for Xus here, used N threads, and had M plan nodes. -- 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