cloud-fan commented on code in PR #39592:
URL: https://github.com/apache/spark/pull/39592#discussion_r1081550033
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/rules/RuleExecutor.scala:
##########
@@ -151,12 +152,15 @@ abstract class RuleExecutor[TreeType <: TreeNode[_]]
extends Logging {
protected val excludedOnceBatches: Set[String] = Set.empty
/**
- * Defines a check function that checks for structural integrity of the plan
after the execution
- * of each rule. For example, we can check whether a plan is still resolved
after each rule in
- * `Optimizer`, so we can catch rules that return invalid plans. The check
function returns
- * `false` if the given plan doesn't pass the structural integrity check.
+ * Defines a validate function that validates the plan changes after the
execution of each rule,
+ * to make sure these rules make valid changes to the plan. For example, we
can check whether
+ * a plan is still resolved after each rule in `Optimizer`, so that we can
catch rules that
+ * turn the plan into unresolved.
*/
- protected def isPlanIntegral(previousPlan: TreeType, currentPlan: TreeType):
Boolean = true
+ // TODO: make each violation a sub error class.
Review Comment:
```suggestion
// TODO: make each violation a sub error class.
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]