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 2019/07/07 14:48:46 UTC

[GitHub] [incubator-iceberg] rdblue commented on a change in pull request #264: Add table UUID

rdblue commented on a change in pull request #264: Add table UUID
URL: https://github.com/apache/incubator-iceberg/pull/264#discussion_r300871070
 
 

 ##########
 File path: core/src/main/java/org/apache/iceberg/SnapshotProducer.java
 ##########
 @@ -231,7 +231,9 @@ public void commit() {
             Snapshot newSnapshot = apply();
             newSnapshotId.set(newSnapshot.snapshotId());
             TableMetadata updated = base.replaceCurrentSnapshot(newSnapshot);
-            taskOps.commit(base, updated);
+            // if the table UUID is missing, add it here. the UUID will be re-created each time this operation retries
+            // to ensure that if a concurrent operation assigns the UUID, this operation will not fail.
+            taskOps.commit(base, updated.withUUID());
 
 Review comment:
   Correct. This identifies a table so you can't start an operation, drop and recreate the table, and then complete the operation. We had it happen once.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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