cloud-fan commented on a change in pull request #34470:
URL: https://github.com/apache/spark/pull/34470#discussion_r769249247
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/QueryPlan.scala
##########
@@ -84,6 +84,13 @@ abstract class QueryPlan[PlanType <: QueryPlan[PlanType]]
AttributeSet.fromAttributeSets(expressions.map(_.references)) --
producedAttributes
}
+ /**
+ * Returns true when the all the expressions in the current node as well as
all of its children
+ * are deterministic
+ */
+ lazy val deterministic: Boolean = expressions.forall(_.deterministic) &&
Review comment:
physical plan can override this `lazy val` if it has custom logic, right?
--
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]