You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2022/09/13 01:13:43 UTC

[GitHub] [pinot] siddharthteotia commented on a diff in pull request #9386: Terminate the query after plan generation if timeout

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


##########
pinot-core/src/test/java/org/apache/pinot/queries/BaseQueriesTest.java:
##########
@@ -264,10 +271,22 @@ private BrokerResponseNative getBrokerResponseDistinctInstances(PinotQuery pinot
     Plan plan1 = planMaker.makeInstancePlan(instances.get(0), serverQueryContext, EXECUTOR_SERVICE, null);
     Plan plan2 = planMaker.makeInstancePlan(instances.get(1), serverQueryContext, EXECUTOR_SERVICE, null);
 
-    DataTable instanceResponse1 =
-        queryContext.isExplain() ? ServerQueryExecutorV1Impl.processExplainPlanQueries(plan1) : plan1.execute();
-    DataTable instanceResponse2 =
-        queryContext.isExplain() ? ServerQueryExecutorV1Impl.processExplainPlanQueries(plan2) : plan2.execute();
+    DataTable instanceResponse1;
+    try {
+      instanceResponse1 =
+          queryContext.isExplain() ? ServerQueryExecutorV1Impl.processExplainPlanQueries(plan1) : plan1.execute();
+    } catch (TimeoutException e) {
+      e.printStackTrace();

Review Comment:
   We don't typically do `e.printStackTrace();`



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