jonvex commented on code in PR #9276:
URL: https://github.com/apache/hudi/pull/9276#discussion_r1284844263
##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/Iterators.scala:
##########
@@ -83,8 +94,8 @@ class LogFileIterator(logFiles: List[HoodieLogFile],
}
.getOrElse(new TypedProperties())
- protected override val avroSchema: Schema = new
Schema.Parser().parse(requiredSchema.avroSchemaStr)
- protected override val structTypeSchema: StructType =
requiredSchema.structTypeSchema
+ protected override val avroSchema: Schema = requiredAvroSchema
Review Comment:
There isn't any functional difference to this code. I just added an
alternate constructor so that I didn't have to create another table schema just
to deconstruct it
```
def this(logFiles: List[HoodieLogFile],
partitionPath: Path,
tableSchema: HoodieTableSchema,
requiredSchema: HoodieTableSchema,
tableState: HoodieTableState,
config: Configuration) {
this(logFiles, partitionPath, tableSchema,
requiredSchema.structTypeSchema,
new Schema.Parser().parse(requiredSchema.avroSchemaStr), tableState,
config)
}
```
--
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]