You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/02/08 04:42:19 UTC

[GitHub] [spark] gatorsmile commented on a change in pull request #26977: [SPARK-30326][SQL] Raise exception if analyzer exceed max iterations

gatorsmile commented on a change in pull request #26977: [SPARK-30326][SQL] Raise exception if analyzer exceed max iterations
URL: https://github.com/apache/spark/pull/26977#discussion_r376687022
 
 

 ##########
 File path: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/rules/RuleExecutor.scala
 ##########
 @@ -156,7 +163,7 @@ abstract class RuleExecutor[TreeType <: TreeNode[_]] extends Logging {
           // Only log if this is a rule that is supposed to run more than once.
           if (iteration != 2) {
             val message = s"Max iterations (${iteration - 1}) reached for batch ${batch.name}"
-            if (Utils.isTesting) {
+            if (Utils.isTesting || batch.strategy.errorOnExceed) {
               throw new TreeNodeException(curPlan, message, null)
 
 Review comment:
   In the message, we need to explicitly tell users how to resolve this exception. Increasing the value of SQLConf.ANALYZER_MAX_ITERATIONS.key

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org