You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by GitBox <gi...@apache.org> on 2022/07/19 00:50:51 UTC

[GitHub] [iceberg] xingfanx commented on a diff in pull request #5304: AWS: handle_s3_glue_exception

xingfanx commented on code in PR #5304:
URL: https://github.com/apache/iceberg/pull/5304#discussion_r923967946


##########
aws/src/integration/java/org/apache/iceberg/aws/glue/TestGlueCatalogCommitFailure.java:
##########
@@ -317,6 +319,49 @@ public void testGlueValidationException() {
     Assert.assertEquals("No new metadata files should exist", 2, metadataFileCount(ops.current()));
   }
 
+  @Test
+  public void testS3Exception() {
+    Table table = setupTable();
+    GlueTableOperations ops = (GlueTableOperations) ((HasTableOperations) table).operations();
+
+    TableMetadata metadataV1 = ops.current();
+    TableMetadata metadataV2 = updateTable(table, ops);
+
+    GlueTableOperations spyOps = Mockito.spy(ops);
+    failCommitAndThrowException(spyOps, S3Exception.builder().build());
+
+    AssertHelpers.assertThrows(
+            null,
+            S3Exception.class,
+            () -> spyOps.commit(metadataV2, metadataV1));

Review Comment:
   I think this aligns with the current indentation scheme



-- 
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: issues-unsubscribe@iceberg.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org