You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by ja...@apache.org on 2024/02/05 18:34:46 UTC

(pinot) branch master updated: [Multi-stage] Fix stage id in stage plan (#12366)

This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
     new 96c3bf2b1e [Multi-stage] Fix stage id in stage plan (#12366)
96c3bf2b1e is described below

commit 96c3bf2b1e4da39536c667ebc7c741f4ef92d0c6
Author: Xiaotian (Jackie) Jiang <17...@users.noreply.github.com>
AuthorDate: Mon Feb 5 10:34:39 2024 -0800

    [Multi-stage] Fix stage id in stage plan (#12366)
---
 .../apache/pinot/query/service/dispatch/QueryDispatcher.java   | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/pinot-query-runtime/src/main/java/org/apache/pinot/query/service/dispatch/QueryDispatcher.java b/pinot-query-runtime/src/main/java/org/apache/pinot/query/service/dispatch/QueryDispatcher.java
index 8336d9aa27..405f619a9b 100644
--- a/pinot-query-runtime/src/main/java/org/apache/pinot/query/service/dispatch/QueryDispatcher.java
+++ b/pinot-query-runtime/src/main/java/org/apache/pinot/query/service/dispatch/QueryDispatcher.java
@@ -155,12 +155,14 @@ public class QueryDispatcher {
         try {
           Worker.QueryRequest.Builder requestBuilder = Worker.QueryRequest.newBuilder();
           for (int i = 0; i < numStages; i++) {
-            DispatchablePlanFragment stagePlan = stagePlans.get(i + 1);
+            int stageId = i + 1;
+            DispatchablePlanFragment stagePlan = stagePlans.get(stageId);
             List<Integer> workerIds = stagePlan.getServerInstanceToWorkerIdMap().get(serverInstance);
             if (workerIds != null) {
-              requestBuilder.addStagePlan(Worker.StagePlan.newBuilder().setStageId(i).setStageRoot(stageRootNodes[i])
-                  .setStageMetadata(QueryPlanSerDeUtils.toProtoStageMetadata(stageWorkerMetadataLists[i],
-                      stagePlan.getCustomProperties(), serverInstance, workerIds)).build());
+              requestBuilder.addStagePlan(
+                  Worker.StagePlan.newBuilder().setStageId(stageId).setStageRoot(stageRootNodes[i]).setStageMetadata(
+                      QueryPlanSerDeUtils.toProtoStageMetadata(stageWorkerMetadataLists[i],
+                          stagePlan.getCustomProperties(), serverInstance, workerIds)).build());
             }
           }
           requestBuilder.putAllMetadata(requestMetadata);


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