yihua commented on code in PR #13572:
URL: https://github.com/apache/hudi/pull/13572#discussion_r2233594097
##########
hudi-client/hudi-spark-client/src/main/scala/org/apache/spark/sql/HoodieInternalRowUtils.scala:
##########
@@ -379,7 +379,7 @@ object HoodieInternalRowUtils {
case (_: DoubleType, _) =>
prevDataType match {
- case _: FloatType => (fieldUpdater, ordinal, value) =>
fieldUpdater.setDouble(ordinal, value.asInstanceOf[Float].toDouble)
+ case _: FloatType => (fieldUpdater, ordinal, value) =>
fieldUpdater.setDouble(ordinal, value.asInstanceOf[Float].toString.toDouble)
Review Comment:
Add a comment to avoid confusion in the future? Does a UT cover this?
##########
hudi-common/src/main/java/org/apache/hudi/common/engine/HoodieReaderContext.java:
##########
@@ -239,10 +250,53 @@ public abstract ClosableIterator<T> getFileRecordIterator(
* @param storage {@link HoodieStorage} for reading records.
* @return {@link ClosableIterator<T>} that can return all records through
iteration.
*/
- public ClosableIterator<T> getFileRecordIterator(
- StoragePathInfo storagePathInfo, long start, long length, Schema
dataSchema, Schema requiredSchema,
- HoodieStorage storage) throws IOException {
- return getFileRecordIterator(storagePathInfo.getPath(), start, length,
dataSchema, requiredSchema, storage);
+ public final ClosableIterator<T> getFileRecordIterator(
Review Comment:
nit: find a way to reduce the number of methods getting record iterators,
i.e., `getFileRecordIterator`, `doGetFileRecordIterator`,
`getFileRecordIteratorInternal`.
##########
hudi-common/src/main/java/org/apache/hudi/avro/HoodieAvroReaderContext.java:
##########
@@ -81,7 +78,7 @@ public HoodieAvroReaderContext(
}
@Override
- public ClosableIterator<IndexedRecord> getFileRecordIterator(
+ protected ClosableIterator<IndexedRecord> doGetFileRecordIterator(
Review Comment:
nit: keep the original method name?
--
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]