Hello Peter Rozsa, Impala Public Jenkins,

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24736

to look at the new patch set (#2).

Change subject: IMPALA-11577: optimize file format counting
......................................................................

IMPALA-11577: optimize file format counting

Previously, IcebergScanNode.populateFileFormats() iterated over every
file descriptor at plan time to determine which file formats (Parquet,
ORC, Avro) are present — an O(n) scan that is wasteful for tables with
many files since the answer is a set of at most 3 values.

This patch precomputes file formats during metadata loading and plan
file discovery, then passes the result as a set to IcebergScanNode via
the constructor. populateFileFormats() becomes a no-op override.

- Catalog path: IcebergContentFileStore tracks formats in an
  EnumSet<TIcebergFileFormat> as files are loaded. The three boolean
  fields (has_avro, has_orc, has_parquet) in the thrift struct are
  replaced with a single set<TIcebergFileFormat>.
- planFiles path: IcebergScanPlanner accumulates formats alongside
  per-file processing that already happens.
- IcebergScanNode converts TIcebergFileFormat to HdfsFileFormat at the
  boundary via an exhaustive switch expression.

Assisted-by: Claude Opus 4.6 (Claude Code)
Change-Id: I3956c72559d562d6a0a8e163042e3ded6cc0c627
---
M common/thrift/CatalogObjects.thrift
M fe/src/main/java/org/apache/impala/catalog/IcebergContentFileStore.java
M fe/src/main/java/org/apache/impala/planner/HdfsScanNode.java
M fe/src/main/java/org/apache/impala/planner/IcebergScanNode.java
M fe/src/main/java/org/apache/impala/planner/IcebergScanPlanner.java
5 files changed, 67 insertions(+), 61 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/36/24736/2
--
To view, visit http://gerrit.cloudera.org:8080/24736
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I3956c72559d562d6a0a8e163042e3ded6cc0c627
Gerrit-Change-Number: 24736
Gerrit-PatchSet: 2
Gerrit-Owner: Nandor Kollar <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Peter Rozsa <[email protected]>

Reply via email to