You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "rfyu (via GitHub)" <gi...@apache.org> on 2023/02/16 01:04:31 UTC
[GitHub] [hudi] rfyu commented on a diff in pull request #7672: [HUDI-5557]Avoid converting columns that are not indexed in CSI
rfyu commented on code in PR #7672:
URL: https://github.com/apache/hudi/pull/7672#discussion_r1107901436
##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/ColumnStatsIndexSupport.scala:
##########
@@ -209,11 +209,11 @@ class ColumnStatsIndexSupport(spark: SparkSession,
// NOTE: We're sorting the columns to make sure final index schema matches layout
// of the transposed table
val sortedTargetColumnsSet = TreeSet(queryColumns:_*)
- val sortedTargetColumns = sortedTargetColumnsSet.toSeq
// NOTE: This is a trick to avoid pulling all of [[ColumnStatsIndexSupport]] object into the lambdas'
// closures below
val indexedColumns = this.indexedColumns
+ val indexedTargetColumns = sortedTargetColumnsSet.filter(indexedColumns.contains(_)).toSeq
Review Comment:
Thanks,I've re-modified.
--
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: commits-unsubscribe@hudi.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org