viirya commented on code in PR #53142:
URL: https://github.com/apache/spark/pull/53142#discussion_r2547577746
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/physical/partitioning.scala:
##########
@@ -951,10 +951,11 @@ case class KeyGroupedShuffleSpec(
}
override def createPartitioning(clustering: Seq[Expression]): Partitioning =
{
- val newExpressions: Seq[Expression] =
clustering.zip(partitioning.expressions).map {
- case (c, e: TransformExpression) => TransformExpression(
- e.function, Seq(c), e.numBucketsOpt)
- case (c, _) => c
+ val clusteringMap =
distribution.clustering.map(_.canonicalized).zip(clustering).toMap
Review Comment:
Should we assert the size of `distribution.clustering` matches `clustering`?
Or they are definitely matched already.
--
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]