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/05/05 02:53:05 UTC

[GitHub] [iceberg] kbendick commented on a diff in pull request #4694: Core: Add all_delete_files and all_files tables

kbendick commented on code in PR #4694:
URL: https://github.com/apache/iceberg/pull/4694#discussion_r865523486


##########
core/src/test/java/org/apache/iceberg/TestMetadataTableFilters.java:
##########
@@ -129,14 +137,28 @@ private int expectedScanTaskCount(int partitions) {
         }
       case DATA_FILES:
       case DELETE_FILES:
+      case ALL_DELETE_FILES:
         return partitions;
       case ALL_DATA_FILES:
         return partitions * 2; // ScanTask for Data Manifest in DELETED and ADDED states
+      case ALL_FILES:
+        if (formatVersion == 1) {
+          return partitions * 2; // ScanTask for Data Manifest in DELETED and ADDED states
+        } else {
+          return partitions * 4; // ScanTask for Delete and Data File in DELETED and ADDED states
+        }
       default:
         throw new IllegalArgumentException("Unsupported metadata table type:" + type);
     }
   }
 
+  private boolean allFileTableTest(MetadataTableType tableType) {
+    return Sets.newHashSet(MetadataTableType.ALL_DATA_FILES,
+            MetadataTableType.ALL_DATA_FILES,
+            MetadataTableType.ALL_FILES)

Review Comment:
   Nit: Consider making this a `static final` constant.



-- 
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