hudi-agent commented on code in PR #19822:
URL: https://github.com/apache/hudi/pull/19822#discussion_r3913108689
##########
hudi-spark-datasource/hudi-spark3-common/src/main/scala/org/apache/spark/sql/execution/datasources/parquet/Spark3LegacyHoodieParquetFileFormat.scala:
##########
@@ -171,7 +171,11 @@ abstract class
Spark3LegacyHoodieParquetFileFormat(shouldAppendPartitionValues:
val int96RebaseModeInRead = parquetOptions.int96RebaseModeInRead
val timeZoneId = Option(sqlConf.sessionLocalTimeZone)
// Whole stage codegen (PhysicalRDD) is able to deal with batches directly.
- val returningBatch = getReturningBatch(sparkSession, resultSchema)
+ // Respect the plan-time OPTION_RETURNING_BATCH decision when present,
instead of recomputing it here.
+ val returningBatch = enableVectorizedReader &&
+ options.get(FileFormat.OPTION_RETURNING_BATCH)
+ .map(_.equals("true"))
Review Comment:
🤖 nit: `_.equals("true")` is Java-style — in Scala `_ == "true"` (or
`_.toBoolean`) is the idiomatic equivalent here.
<sub><i>⚠️ AI-generated; verify before applying. React 👍/👎 to flag
quality.</i></sub>
--
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]