alexeykudinkin commented on code in PR #5943:
URL: https://github.com/apache/hudi/pull/5943#discussion_r928053904
##########
hudi-spark-datasource/hudi-spark/src/main/scala/org/apache/spark/sql/hudi/analysis/HoodieAnalysis.scala:
##########
@@ -44,15 +44,26 @@ import scala.collection.mutable.ListBuffer
object HoodieAnalysis {
type RuleBuilder = SparkSession => Rule[LogicalPlan]
- def customOptimizerRules: Seq[RuleBuilder] =
- if (HoodieSparkUtils.gteqSpark3_1) {
- val nestedSchemaPruningClass =
"org.apache.spark.sql.execution.datasources.NestedSchemaPruning"
+ def customOptimizerRules: Seq[RuleBuilder] = {
+ if (HoodieSparkUtils.gteqSpark3_3) {
Review Comment:
We can reduce the conditional to just instantiate the actual rule and
extract common `Seq(_ => rule)`
--
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]