RussellSpitzer commented on code in PR #4673:
URL: https://github.com/apache/iceberg/pull/4673#discussion_r862384281


##########
core/src/main/java/org/apache/iceberg/SnapshotProducer.java:
##########
@@ -343,11 +343,15 @@ public void commit() {
         LOG.warn("Failed to load committed snapshot, skipping manifest 
clean-up");
       }
 
-    } catch (RuntimeException e) {
-      LOG.warn("Failed to load committed table metadata, skipping manifest 
clean-up", e);
+    } catch (Throwable e) {

Review Comment:
   I think that may be possible... All of our tests at the moment just make 
sure that the Metadata.json file is not incorrectly removed. We probably should 
add an additional test to make sure data files in Spark are not removed. I 
would think we would need a catch 
[here](https://github.com/apache/iceberg/blob/master/spark/v3.2/spark/src/main/java/org/apache/iceberg/spark/source/SparkWrite.java#L199)
 
   
   ```
       try {
         operation.commit(); // abort is automatically called if this fails
       } catch (CommitStateUnknownException commitStateUnknownException) {
         LOG.warn("Unknown Commit State", commitStateUnknownException);
       }
   ```



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