danielcweeks commented on code in PR #6850: URL: https://github.com/apache/iceberg/pull/6850#discussion_r1110469210
########## core/src/main/java/org/apache/iceberg/rest/RESTSessionCatalog.java: ########## @@ -302,13 +323,29 @@ public Table loadTable(SessionContext context, TableIdentifier identifier) { } AuthSession session = tableSession(response.config(), session(context)); + TableMetadata tableMetadata; + + if (snapshotMode == SnapshotMode.REFS) { + tableMetadata = + TableMetadata.buildFrom(response.tableMetadata()) + .setSnapshotsSupplier( + () -> + loadInternal(context, identifier, SnapshotMode.ALL) + .tableMetadata() + .snapshots()) + .discardChanges() Review Comment: Yes, this is just to ensure that we aren't building anything that might get passed on in the metadata response. -- 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-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org