[AURON #2431] Prune Iceberg changelog tasks by metadata predicates (#2456)

# Which issue does this PR close?

Closes #2431

# Rationale for this change

Iceberg changelog metadata values are constant per changelog task. Auron
currently plans every supported `AddedRowsScanTask` in a changelog range
even when a simple predicate on `_change_type`, `_commit_snapshot_id`,
or `_change_ordinal` proves that a task cannot match.

# What changes are included in this PR?

- Associate supported metadata-only filters with a direct Iceberg
changelog scan, allowing only deterministic projections between the
filter and scan.
- Match filter attributes to the scan by expression ID before tagging
it.
- Prepare extension plans in the existing pre-columnar transition pass.
- Prune `AddedRowsScanTask` instances for `=` and `IN` predicates
combined with `AND`.
- Preserve the changelog filter tag when Spark rebuilds a
`BatchScanExec` for runtime filters.
- Keep `OR`, `NOT`, mixed data-column predicates, unsafe operator
shapes, and non-`AddedRowsScanTask` tasks on the existing path.

# Are there any user-facing changes?

Yes. Eligible native Iceberg changelog scans plan and read fewer insert
tasks. There are no public API or configuration changes.

# How was this patch tested?

- `AuronIcebergIntegrationSuite`: 45 tests passed on Spark 3.5 / Iceberg
1.10.1 with the native engine.
- `./dev/reformat --check`: passed both Spark 3.5 formatting
configurations and compile/test-compile across Spark 3.0-3.4 and Spark
4.0-4.1.
- Regressions cover supported and unsupported predicates,
aggregate/limit/nondeterministic barriers, expression-ID mismatches,
pre-columnar staging, runtime-filter copies, dynamic partition pruning,
and retention of non-insert tasks.

# Was this patch authored or co-authored using generative AI tooling?
- [x] Yes
- [ ] No

Generated-by: OpenAI Codex (GPT-5.6)

Co-authored-by: Shilun Fan <slfan1989@apache.org>
Signed-off-by: Shilun Fan <slfan1989@apache.org>
6 files changed
tree: bd257360d1d5aaa406e32905dd6e1f67102f4541
  1. .github/
  2. .idea/
  3. auron-core/
  4. auron-flink-extension/
  5. auron-spark-tests/
  6. auron-spark-ui/
  7. benchmark-results/
  8. build/
  9. common/
  10. dev/
  11. hadoop-shim/
  12. native-engine/
  13. spark-extension/
  14. spark-extension-shims-spark/
  15. spark-version-annotation-macros/
  16. thirdparty/
  17. .asf.yaml
  18. .gitattributes
  19. .gitignore
  20. .gitmodules
  21. .rat-excludes
  22. AGENTS.md
  23. auron-build.sh
  24. Cargo.lock
  25. Cargo.toml
  26. CONTRIBUTING.md
  27. DISCLAIMER
  28. LICENSE
  29. NOTICE
  30. pom.xml
  31. README.md
  32. rust-toolchain.toml
  33. rustfmt.toml
  34. scalafix.conf
  35. scalafmt.conf
README.md

Apache Auron (Incubating)

TPC-DS master-amd64-builds

The Auron accelerator for big data engines (e.g., Spark, Flink) leverages native vectorized execution to accelerate query processing. It combines the power of the Apache DataFusion library and the scale of the distributed computing framework.

Auron takes a fully optimized physical plan from a distributed computing framework, mapping it into DataFusion's execution plan, and performs native plan computation.

The key capabilities of Auron include:

  • Native execution: Implemented in Rust, eliminating JVM overhead and enabling predictable performance.
  • Vectorized computation: Built on Apache Arrow's columnar format, fully leveraging SIMD instructions for batch processing.
  • Pluggable architecture: Seamlessly integrates with Apache Spark while designed for future extensibility to other engines.
  • Production-hardened optimizations: Multi-level memory management, compacted shuffle formats, and adaptive execution strategies developed through large-scale deployment.

Based on the inherent well-defined extensibility of DataFusion, Auron can be easily extended to support:

  • Various object stores.
  • Operators.
  • Simple and Aggregate functions.
  • File formats.

We encourage you to extend DataFusion capability directly and add support in Auron with simple modifications in plan-serde and extension translation.

Build from source

To build Auron from source, follow the steps below:

  1. Install Rust

Auron's native execution lib is written in Rust. You need to install Rust (nightly) before compiling.

We recommend using rustup for installation.

  1. Install JDK

Auron is regularly tested on JDK 8, 11, and 17, and is also tested on JDK 21.

Make sure JAVA_HOME is properly set and points to your desired version.

  1. Check out the source code.

  2. Build the project.

You can build Auron either locally or inside Docker using one of the supported OS images via the unified script: auron-build.sh.

Run ./auron-build.sh --help to see all available options.

After the build completes, a fat JAR with all dependencies will be generated in either the target/ directory (for local builds) or target-docker/ directory (for Docker builds), depending on the selected build mode.

Run Spark Job with Auron Accelerator

This section describes how to submit and configure a Spark Job with Auron support.

  1. Move the Auron JAR to the Spark client classpath (normally spark-xx.xx.xx/jars/).

  2. Add the following configs to spark configuration in spark-xx.xx.xx/conf/spark-default.conf:

spark.auron.enable true
spark.sql.extensions org.apache.spark.sql.auron.AuronSparkSessionExtension
spark.shuffle.manager org.apache.spark.sql.execution.auron.shuffle.AuronShuffleManager
spark.memory.offHeap.enabled false

# suggested executor memory configuration
spark.executor.memory 4g
spark.executor.memoryOverhead 4096
  1. submit a query with spark-sql, or other tools like spark-thriftserver:
spark-sql -f tpcds/q01.sql

Performance

TPC-DS 1TB Benchmark Results:

tpcds-benchmark-echarts.png

For methodology and additional results, please refer to benchmark documentation.

We also encourage you to benchmark Auron and share the results with us. 🤗

Community

Subscribe Mailing Lists

Mail List is the most recognized form of communication in the Apache community. Contact us through the following mailing list.

NameScope
dev@auron.apache.orgDevelopment-related discussionsSubscribeUnsubscribe

Contributing

Interested in contributing to Auron? Please read our Contributing Guide for detailed information on how to get started.

License

Auron is licensed under the Apache 2.0 License. A copy of the license can be found here.