amogh-jahagirdar commented on code in PR #4922:
URL: https://github.com/apache/iceberg/pull/4922#discussion_r887296820


##########
core/src/main/java/org/apache/iceberg/TableMetadata.java:
##########
@@ -120,13 +120,15 @@ static TableMetadata newTableMetadata(Schema schema,
     // break existing tables.
     MetricsConfig.fromProperties(properties).validateReferencedColumns(schema);
 
+    SnapshotRef main = SnapshotRef.branchBuilder(-1).build();

Review Comment:
   Good point, I was originally thinking that at least the ref can exist even 
if there is no table state. But it's easier to just maintain the invariant that 
so long as there's no table state, main won't exist.



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