rdblue commented on a change in pull request #2617:
URL: https://github.com/apache/iceberg/pull/2617#discussion_r655768624
##########
File path: core/src/main/java/org/apache/iceberg/StaticTableScan.java
##########
@@ -37,6 +38,28 @@ private StaticTableScan(TableOperations ops, Table table,
Schema schema,
this.buildTask = buildTask;
}
+ /**
+ * Type of scan being performed by the buildTask, such as {@link
MetadataTableType#HISTORY} when scanning
+ * a table's {@link org.apache.iceberg.HistoryTable}.
+ * <p>
+ * Used for logging and error messages.
+ */
+ protected String tableType() {
+ return "static";
+ }
+
+ @Override
+ public TableScan appendsBetween(long fromSnapshotId, long toSnapshotId) {
+ throw new UnsupportedOperationException(
+ String.format("Incremental scan is not supported for %s scan of table
%s", tableType(), table().name()));
+ }
+
+ @Override
+ public TableScan appendsAfter(long fromSnapshotId) {
+ throw new UnsupportedOperationException(
+ String.format("Incremental scan is not supported for %s scan of table
%s", tableType(), table().name()));
Review comment:
This error message makes it sound like it is a combination of the table
and the metadata table type, but no metadata tables support incremental scan
(yet?).
I think this should state that the metadata table does not support
incremental scan: `"Cannot incrementally scan metadata table: %s"`
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]