Github user gatorsmile commented on a diff in the pull request: https://github.com/apache/spark/pull/18697#discussion_r136378843 --- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/physical/partitioning.scala --- @@ -171,6 +171,16 @@ sealed trait Partitioning { * produced by `A` could have also been produced by `B`. */ def guarantees(other: Partitioning): Boolean = this == other + + /** + * Returns the partitioning scheme that is valid under restriction to a given set of output + * attributes. If the partitioning is an [[Expression]] then the attributes that it depends on + * must be in the outputSet otherwise the attribute leaks. + */ + def restrict(outputSet: AttributeSet): Partitioning = this match { --- End diff -- We are refactoring the concept in the PR https://github.com/apache/spark/pull/19080 Please review that PR first? Thanks!
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org