nastra commented on code in PR #11948: URL: https://github.com/apache/iceberg/pull/11948#discussion_r1916827033
########## core/src/main/java/org/apache/iceberg/TableMetadata.java: ########## @@ -1468,6 +1514,45 @@ public Builder setPreviousFileLocation(String previousFileLocation) { return this; } + private Builder setRowLineage(Boolean newRowLineage) { + if (newRowLineage == null) { + return this; + } + + boolean disablingRowLineage = rowLineage && !newRowLineage; + + Preconditions.checkArgument( + !disablingRowLineage, "Cannot disable row lineage once it has been enabled"); + + if (!rowLineage && newRowLineage) { + return enableRowLineage(); + } else { + return this; + } + } + + public Builder enableRowLineage() { Review Comment: it feels a bit weird to have both methods to effectively do the same. Maybe we should just reduce this to having a single method? -- 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