RussellSpitzer commented on code in PR #7770: URL: https://github.com/apache/iceberg/pull/7770#discussion_r1543752014
########## core/src/main/java/org/apache/iceberg/SnapshotParser.java: ########## @@ -93,6 +95,16 @@ static void toJson(Snapshot snapshot, JsonGenerator generator) throws IOExceptio generator.writeNumberField(SCHEMA_ID, snapshot.schemaId()); } + if (snapshot.manifestListKeyMetadata() != null) { + generator.writeStringField(MANIFEST_LIST_KEY_METADATA, snapshot.manifestListKeyMetadata()); + } + + // TODO discuss: do we need to sign the size value? Or sign the whole snapshot? + // Or rely on REST catalog? - the only option that prevents "full folder replacement" attack. + if (snapshot.manifestListSize() >= 0) { Review Comment: another small question here, we essentially are doing a transform here manifestlists sizes < 0 become 0. Also nit: we are also ignoring 0's that get passed through although we will read this as 0 if it is missing. Just wondering what the intent here is. I think it may be better to have a defined missing value? Not sure -- 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