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 2022/03/30 17:35:15 UTC
[GitHub] [iceberg] amogh-jahagirdar commented on a change in pull request #4428: Core, API: Support table scan from a ref
amogh-jahagirdar commented on a change in pull request #4428:
URL: https://github.com/apache/iceberg/pull/4428#discussion_r838801666
##########
File path: api/src/main/java/org/apache/iceberg/TableScan.java
##########
@@ -49,6 +49,24 @@
*/
TableScan useSnapshot(long snapshotId);
+ /**
+ * Create a new {@link TableScan} from this scan's configuration that will use the given branch
+ *
+ * @param branch the branch to scan from
+ * @return a new scan based on this with the given branch
+ * @throws IllegalArgumentException if the branch cannot be found
+ */
+ TableScan branch(String branch);
Review comment:
It's a good point. My thought was that from an API point of view people would be more familiar with the terms branch and tag, so they would leverage that. I also think if is using this, they know before hand if it's a branch or a tag, so it's not cumbersome. But yeah currently, the logic is effectively the same which is to use the snapshot for the reference.
Thoughts?
--
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-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org