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/04/06 17:57:28 UTC

[GitHub] [pinot] walterddr commented on a diff in pull request #10481: [refactor] add physical planner

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


##########
pinot-query-planner/src/main/java/org/apache/pinot/query/planner/physical/DispatchablePlanContext.java:
##########
@@ -0,0 +1,64 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pinot.query.planner.physical;
+
+import java.util.HashMap;
+import java.util.List;
+import org.apache.calcite.util.Pair;
+import org.apache.pinot.query.context.PlannerContext;
+import org.apache.pinot.query.planner.QueryPlan;
+import org.apache.pinot.query.routing.WorkerManager;
+
+
+public class DispatchablePlanContext {
+  private final WorkerManager _workerManager;
+  private final long _requestId;
+  private final PlannerContext _plannerContext;
+  private final List<Pair<Integer, String>> _fields;
+  private final QueryPlan _queryPlan;
+
+  public DispatchablePlanContext(WorkerManager workerManager, long requestId, PlannerContext plannerContext,
+      List<Pair<Integer, String>> resultFields) {
+    _workerManager = workerManager;
+    _requestId = requestId;
+    _plannerContext = plannerContext;
+    _fields = resultFields;
+    _queryPlan = new QueryPlan(_fields, new HashMap<>(), new HashMap<>());
+  }
+
+  public QueryPlan getQueryPlan() {
+    return _queryPlan;
+  }
+
+  public WorkerManager getWorkerManager() {
+    return _workerManager;
+  }
+
+  public long getRequestId() {
+    return _requestId;
+  }
+
+  public PlannerContext getPlannerContext() {
+    return _plannerContext;
+  }
+
+  public List<Pair<Integer, String>> getFields() {

Review Comment:
   removed the member val



-- 
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