singhpk234 commented on code in PR #5864:
URL: https://github.com/apache/iceberg/pull/5864#discussion_r981553246


##########
core/src/main/java/org/apache/iceberg/hadoop/HadoopInputFile.java:
##########
@@ -224,9 +224,13 @@ public String location() {
   @Override
   public boolean exists() {
     try {
-      return fs.exists(path);
-    } catch (IOException e) {
-      throw new RuntimeIOException(e, "Failed to check existence for file: 
%s", path);
+      return lazyStat() != null;
+    } catch (RuntimeIOException re) {
+      if (re.getCause() instanceof FileNotFoundException) {

Review Comment:
   I think it makes sense :) , we kind of have similar handling for NoSuchKey 
exception. made the corresponding changes !



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to