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 54fefe7f53 Improve error message for max rows in join limit breach 
(#13394)
54fefe7f53 is described below

commit 54fefe7f5354ff1093773559feeb91ca2aed7dfc
Author: Yash Mayya <[email protected]>
AuthorDate: Tue Jun 18 02:12:06 2024 +0200

    Improve error message for max rows in join limit breach (#13394)
---
 .gitignore                                                 |  1 +
 .../pinot/query/runtime/operator/HashJoinOperator.java     | 14 +++++++++++---
 2 files changed, 12 insertions(+), 3 deletions(-)

diff --git a/.gitignore b/.gitignore
index c3b52d6e04..ca69e90d0e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,6 +6,7 @@ cscope.*
 .externalToolBuilders/
 maven-eclipse.xml
 target/
+examples/
 bin/
 */bin/
 .idea
diff --git 
a/pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/HashJoinOperator.java
 
b/pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/HashJoinOperator.java
index 379073f5af..f224a69aa5 100644
--- 
a/pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/HashJoinOperator.java
+++ 
b/pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/HashJoinOperator.java
@@ -46,11 +46,11 @@ import 
org.apache.pinot.query.runtime.operator.operands.TransformOperandFactory;
 import org.apache.pinot.query.runtime.plan.MultiStageQueryStats;
 import org.apache.pinot.query.runtime.plan.OpChainExecutionContext;
 import org.apache.pinot.spi.utils.BooleanUtils;
+import org.apache.pinot.spi.utils.CommonConstants;
 import 
org.apache.pinot.spi.utils.CommonConstants.MultiStageQueryRunner.JoinOverFlowMode;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-
 /**
  * This basic {@code BroadcastJoinOperator} implement a basic broadcast join 
algorithm.
  * This algorithm assumes that the broadcast table has to fit in memory since 
we are not supporting any spilling.
@@ -237,8 +237,16 @@ public class HashJoinOperator extends MultiStageOperator {
           ProcessingException resourceLimitExceededException =
               new 
ProcessingException(QueryException.SERVER_RESOURCE_LIMIT_EXCEEDED_ERROR_CODE);
           resourceLimitExceededException.setMessage(
-              "Cannot build in memory hash table for join operator, reach 
number of rows limit: "
-                  + _maxRowsInHashTable);
+              "Cannot build in memory hash table for join operator, reach 
number of rows limit: " + _maxRowsInHashTable
+                  + ". Consider increasing the limit for the maximum number of 
rows in a join either via the query "
+                  + "option '" + 
CommonConstants.Broker.Request.QueryOptionKey.MAX_ROWS_IN_JOIN + "' or the '"
+                  + PinotHintOptions.JoinHintOptions.MAX_ROWS_IN_JOIN + "' 
hint in the '"
+                  + PinotHintOptions.JOIN_HINT_OPTIONS + "'. Alternatively, if 
partial results are acceptable, the join"
+                  + " overflow mode can be set to '" + 
JoinOverFlowMode.BREAK.name() + "' either via the query option '"
+                  + 
CommonConstants.Broker.Request.QueryOptionKey.JOIN_OVERFLOW_MODE + "' or the '"
+                  + PinotHintOptions.JoinHintOptions.JOIN_OVERFLOW_MODE + "' 
hint in the '"
+                  + PinotHintOptions.JOIN_HINT_OPTIONS + "'. Furthermore, if 
there is a large disparity in the size of "
+                  + "the two tables being joined, use the smaller table as the 
right input instead of the left.");
           throw resourceLimitExceededException;
         } else {
           // Just fill up the buffer.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to