Arnab Karmakar has posted comments on this change. ( https://gerrit.cloudera.org/25196 )
Change subject: IMPALA-15639: Don't trust the bounds of migrated Iceberg data files ...................................................................... Patch Set 1: (9 comments) Thanks for working on this! https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java File fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java: https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java@237 PS1, Line 237: private boolean hasImportedDataFiles_ = false; Its declared under the immutable members section but we do mutate it through updateHasImportedDataFiles() and this can then be copied by cloneWithoutMutables() by value. I think this could be a potential issue. https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java@345 PS1, Line 345: iceApiTable.location() nit: Can we assign this outside the loop? String apiTableLocation = iceApiTable.location(); and call it like this: fd.getAbsolutePath(apiTableLocation) https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java@369 PS1, Line 369: /** I think the javadoc is missing mentions about write.data.path and obj store locations. https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java@399 PS1, Line 399: hasImportedDataFiles_ = dataLocations.stream().noneMatch(path::startsWith); Is a stream per file necessary? I think a simple for loop would be cheaper. https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/planner/IcebergScanPlanner.java File fe/src/main/java/org/apache/impala/planner/IcebergScanPlanner.java: https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/planner/IcebergScanPlanner.java@1072 PS1, Line 1072: private boolean hasOnlyIdentityPartitionColumns(List<IcebergColumn> cols) { Can we reuse IcebergUtil.isIdentityPartitionedInAllSpecs() instead of a new helper? https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/util/MigrateTableUtil.java File fe/src/main/java/org/apache/impala/util/MigrateTableUtil.java: https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/util/MigrateTableUtil.java@254 PS1, Line 254: * Returns the ids of the fields whose bounds can't be read from the file footers: the Does TypeID.TIMESTAMP also cover timestamptz. If so, we can mention it here. https://gerrit.cloudera.org/#/c/25196/1/fe/src/main/java/org/apache/impala/util/MigrateTableUtil.java@270 PS1, Line 270: private static DataFile removeUnreliableBounds(DataFile dataFile, Params params) { I think we are rebuilding every DataFile and Metrics even when the file has no bounds for the affected fields. Can we skip files whose bounds dont include those ids? https://gerrit.cloudera.org/#/c/25196/1/testdata/workloads/functional-query/queries/QueryTest/iceberg-migrate-from-external-hdfs-tables.test File testdata/workloads/functional-query/queries/QueryTest/iceberg-migrate-from-external-hdfs-tables.test: https://gerrit.cloudera.org/#/c/25196/1/testdata/workloads/functional-query/queries/QueryTest/iceberg-migrate-from-external-hdfs-tables.test@387 PS1, Line 387: ---- QUERY I think we're missing a case for append-only reload after the table has imported files. Can we also cover the write.data.path and object-store in getDataLocations? https://gerrit.cloudera.org/#/c/25196/1/testdata/workloads/functional-query/queries/QueryTest/iceberg-migrate-from-external-hdfs-tables.test@412 PS1, Line 412: Only counts I think we still collect value and null counts. -- To view, visit https://gerrit.cloudera.org/25196 To unsubscribe, visit https://gerrit.cloudera.org/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: Id993ebe1e4c1daed3da1362c6e063c02f9a710d7 Gerrit-Change-Number: 25196 Gerrit-PatchSet: 1 Gerrit-Owner: Zoltan Borok-Nagy <[email protected]> Gerrit-Reviewer: Arnab Karmakar <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Peter Rozsa <[email protected]> Gerrit-Comment-Date: Mon, 09 Nov 2026 09:02:40 +0000 Gerrit-HasComments: Yes
