yihua commented on code in PR #17560:
URL: https://github.com/apache/hudi/pull/17560#discussion_r2613124565


##########
hudi-hadoop-mr/src/main/java/org/apache/hudi/hadoop/utils/HoodieInputFormatUtils.java:
##########
@@ -526,8 +524,8 @@ public static String getTableBasePath(InputSplit split, 
JobConf jobConf) throws
       return realtimeSplit.getBasePath();
     } else {
       Path inputPath = ((FileSplit) split).getPath();
-      FileSystem fs = inputPath.getFileSystem(jobConf);
-      HoodieStorage storage = new HoodieHadoopStorage(fs);
+      HoodieStorage storage = HoodieStorageUtils.getStorage(
+              new StoragePath(inputPath.toUri()), 
HadoopFSUtils.getStorageConf(jobConf));

Review Comment:
   nit: use `HadoopFSUtils.convertToStoragePath`



##########
hudi-hadoop-mr/src/main/java/org/apache/hudi/hadoop/utils/HoodieRealtimeRecordReaderUtils.java:
##########
@@ -312,7 +313,7 @@ public static Schema addPartitionFields(Schema schema, 
List<String> partitioning
   public static HoodieFileReader getBaseFileReader(Path path, JobConf conf) 
throws IOException {
     StorageConfiguration<?> storageConf = HadoopFSUtils.getStorageConf(conf);
     HoodieConfig hoodieConfig = getReaderConfigs(storageConf);
-    return HoodieIOFactory.getIOFactory(new HoodieHadoopStorage(path, conf))
+    return HoodieIOFactory.getIOFactory(HoodieStorageUtils.getStorage(new 
StoragePath(path.toUri()), storageConf))

Review Comment:
   Same here



-- 
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]

Reply via email to