You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by gatorsmile <gi...@git.apache.org> on 2017/09/07 17:48:27 UTC
[GitHub] spark pull request #18956: [SPARK-21726][SQL] Check for structural integrity...
Github user gatorsmile commented on a diff in the pull request:
https://github.com/apache/spark/pull/18956#discussion_r137609405
--- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/rules/RuleExecutor.scala ---
@@ -93,6 +101,13 @@ abstract class RuleExecutor[TreeType <: TreeNode[_]] extends Logging {
""".stripMargin)
}
+ // Run the structural integrity checker against the plan after each rule.
+ if (!planChecker(result)) {
+ val message = s"After applying rule ${rule.ruleName} in batch ${batch.name}, " +
+ "the structural integrity of the plan is broken."
+ throw new TreeNodeException(result, message, null)
--- End diff --
move the exception throwing logics into the `planChecker `?
---
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org