nsivabalan commented on code in PR #6031:
URL: https://github.com/apache/hudi/pull/6031#discussion_r965431934


##########
hudi-common/src/main/java/org/apache/hudi/common/fs/FSUtils.java:
##########
@@ -632,6 +635,15 @@ public static boolean isGCSFileSystem(FileSystem fs) {
     return fs.getScheme().equals(StorageSchemes.GCS.getScheme());
   }
 
+  /**
+   * Some filesystem(such as chdfs) will throw {@code IOException} instead of 
{@code EOFException}. It will cause error in isBlockCorrupted().
+   * Wrapped by {@code BoundedFsDataInputStream}, to check whether the desired 
offset is out of the file size in advance.
+   */
+  public static boolean shouldWrappedByBoundedDataStream(FileSystem fs) {

Review Comment:
   can we keep it simple for now. 
   ```
     public static boolean isCHDSFileSystem(FileSystem fs) {
       return fs.getScheme().equals(StorageSchemes.CHDS.getScheme());
     }
   ```
   
   if at all we come across other storage schemes which might need this, we can 
make it a map. 
   



-- 
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: commits-unsubscr...@hudi.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to