Repository navigation
Conversation
…store 0.14 Point the DataFusion dependencies at a git revision of apache/datafusion main (350ca76505c9513d16e7dd9910bcd9bde2c911ed), which is on arrow/parquet 60.0.0 and object_store 0.14.2. Bump arrow, parquet, object_store and object_store_opendal (0.59.0, the first release on object_store 0.14) to match. iceberg-rust main is still on arrow 59, and the head of apache/iceberg-rust#3257 (Arrow 60) is 42 commits behind the main revision Comet builds against. Pin iceberg and iceberg-storage-opendal to a branch on the andygrove/iceberg-rust fork that merges apache/iceberg-rust main (1f3bc34) into that PR. Source changes for the new APIs: - Arrow 60 makes the FFI_ArrowArrayStream callbacks private, so the decimal-realignment test builds the import with from_ffi_and_data_type. - Parquet 60 moves the page index behind ParquetMetaData::page_index(), a PageIndexProvider with per-row-group access. - DataFusion's coerce_int96 and coerce_int96_tz are typed (DFTimeUnit, ConfigTimeZone) instead of strings. - OffsetBuffer::first/last return values and schema metadata is arrow's Metadata type. - HashJoinExec::with_dynamic_filter_expr, SortExec::with_dynamic_filter_expr, ExecutionPlan::with_preserve_order and ParquetAccessPlan::into_overall_row_selection are deprecated; allow them where Comet still needs them. - Arrow 60's MapBuilder names map children key/value by default, so make_map_c names them keys/values explicitly to keep exercising non-canonical names. - datafusion-spark's SparkXxhash64 now ignores the hidden children of a NULL struct and keeps the running hash for nested dictionaries (apache/datafusion #25774, #25813), so the tests that pinned those differences assert equality.
…ore its test Parquet 60 writes NaN min/max statistics for a float or double column chunk holding only NaN, and iceberg-rust copies them into the manifest bounds, where iceberg-java records none. Ignore the parity test that catches it, list the issue under the Iceberg known issues and add it to the 1.3.0 upgrade guide. It is tracked in #7242.
22 of 47 tasks
Point the DataFusion dependencies at the head of apache/datafusion branch-56 (1635ed94742c1c060852bc34dc6ebb2302241c7b), cut for the 56.0.0 release. It is 116 commits past the previous main revision and moves arrow/parquet to 60.1.0. - Bump arrow, arrow-data, arrow-select and parquet to 60.1.0. - Bump parking_lot to 0.13, which DataFusion's LazyBatchGenerator API now uses. - Rename ArrowArrayStreamReader to RecordBatchStreamReader (deprecated alias). - Use FixedSizeListArray::value_offset_at instead of the deprecated value_offset. - Arrow 60.1.0 encodes the IPC frame in the RSS bounded-buffer test 2048 bytes smaller, so the test measures the frame size instead of hard-coding it.
DataFusion 56 coerces nested BINARY file fields to Utf8 before the parquet reader, which skips UTF-8 validation for unannotated BINARY columns, so the native scan panics in debug builds instead of decoding to U+FFFD. Ignore the Rust and JVM tests from #7106 until apache/datafusion#27065 is fixed (#7469).
…d setters DataFusion 56 deprecates HashJoinExec::with_dynamic_filter_expr and SortExec::with_dynamic_filter_expr with no replacement. Comet does not need them: - A SortExec with a fetch creates its own TopK filter, so the runtime TopK takes that filter from dynamic_expressions_produced() and hands it to the Parquet reader below the sort, instead of installing one from outside. - For joins, Comet reports to HashJoinExec::handle_child_pushdown_result what DataFusion's FilterPushdown rule would: the probe-side self filter was pushed down. The join then installs the filter itself after finding Comet's consumer in its probe subtree.
DataFusion 56 renames OrderedFinalAggregateStream to ClusteredFinalAggregateStream (apache/datafusion#24697), and the memory consumer with it. The fair pool's exemption for that consumer and the spill replay pool's final-aggregate check match it by name, so on DataFusion 56 neither matched anymore. Match the new name, and update the tests, docs and comments that use the old one.
# Conflicts: # native/native-executors/Cargo.lock
DataFusion 56 includes apache/datafusion#25383, which leaves room for a final aggregate to read its spill files back, so SpillReplayPool is no longer needed. It is also now harmful: #25383 holds replay headroom on a sibling reservation while the spill merge picks its files, so the pool took every refused read-buffer request for a replay and granted it. The merge then opened every spill file and starved the next aggregate, which failed the #6880 PartialMerge test with a 2 MiB pool. The #6254 and #6857 read-back tests, which the pool was added for, pass without it. The sort-merge join #6880 test now uses an 8 MiB pool, because with DataFusion 56 its PartialMerge fits in 12 MiB or more without spilling. Closes #6583.
Move the andygrove/iceberg-rust fork pin to apache/iceberg-rust#3257 with apache/iceberg-rust main at 46e51d8 merged in. Main now includes apache/iceberg-rust#3539, which skips NaN min and max statistics when aggregating Parquet column bounds, so the native writer no longer records NaN manifest bounds for all-NaN float and double columns on Parquet 60. This fixes the Iceberg TestAggregatePushDown testNaN and testAllNaN failures, re-enables the NaN manifest metrics test, and drops the known issue from the docs. Closes #7242.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Part of #6410, which tracks the regressions this PR finds. The all-NaN Iceberg bound regression is tracked in #7242 and the nested BINARY UTF-8 regression in #7469. This is a long-lived draft that tracks DataFusion's
branch-56until DataFusion 56.0.0 is released, and it is not meant to merge before then. Related: #5477, whose Arrow 60 items it unblocks.This replaces #6404, moving the branch from a fork to
datafusion-56in this repository.Rationale for this change
DataFusion has cut
branch-56for the 56.0.0 release, and this PR pins its head,1635ed9(2026-11-03). Since 55.2.0 DataFusion has moved to arrow/parquet 60.1.0 and object_store 0.14.2 (apache/datafusion#25335, apache/datafusion#26867), and it has a number of API changes (see its 56.0.0 upgrade guide). Building Comet against the release branch now surfaces the breaks early and lets CI run the Comet suites against it, rather than finding everything at release time.The branch has current
apache/main(1ad7938) merged in.What changes are included in this PR?
Dependencies
datafusion,datafusion-datasource,datafusion-functions,datafusion-physical-expr-adapteranddatafusion-sparkin the workspace now usegit = "https://github.com/apache/datafusion", rev = "1635ed9...", the head ofbranch-56. So do thedatafusion-functions-nesteddev-dependency in core,datafusionin both contrib crates and thenative-executorsworkspace.arrow,arrow-data,arrow-selectandparquetgo from 59.2.0 to 60.1.0.object_storegoes from 0.13.2 to 0.14.2.object_store_opendalgoes from 0.58.0 to 0.59.0, the first release on object_store 0.14. That release keeps opendal on 0.58, which is what iceberg-rust uses.parking_lotgoes from 0.12 to 0.13, the version DataFusion'sLazyBatchGeneratorAPI now uses.icebergandiceberg-storage-opendalmove to1f52867, a branch on the andygrove/iceberg-rust fork.0d5eb12) is behind the iceberg-rust main revision that Comet'smainbuilds against (b154603), and Comet's Iceberg code uses APIs from the commits in between. So the fork branch is build: reduce overhead of fuzz testing #3257's head withb154603merged in.native/Cargo.lockandcontrib/delta/native/Cargo.lockare regenerated.Source changes (all forced by the upgrade)
ArrowArrayStreamReaderin favor ofRecordBatchStreamReader, andFixedSizeListArray::value_offsetin favor ofvalue_offset_at. Comet uses the new names.FFI_ArrowArrayStreamcallbacks private, so the decimal-realignment test inscan.rscan no longer build a hand-rolled C stream. It now exports a struct array and imports it withfrom_ffi_and_data_type, the callRecordBatchStreamReader::nextmakes.AlignedArrowStreamReaderwas already gone on main.ParquetMetaData::page_index(), aPageIndexProviderwith per-row-group access.with_spark_arrow_schemaand the rebase footer rewrite carry it over withset_page_index.page_selection_bound_selectorsindelta_dv.rswalks the row groups throughpage_index_for_row_group.page_index()instead ofcolumn_index()/offset_index().AggregateExec::input_order_mode()is nowgroup_clustering_mode(), returning aGroupClusteringMode. Two planner tests and amin_max_structtest use it.OrderedFinalAggregateStreamand its memory consumer toClusteredFinalAggregateStream. The fair pool's exemption and the spill replay pool's final-aggregate check match that consumer by name, so they now match the new name. Without this they silently stopped applying.coerce_int96andcoerce_int96_tzare now typed (DFTimeUnit,ConfigTimeZone) instead of strings.GetResult::extensions, whichScanIoObjectStore::get_optsnow forwards.OffsetBuffer::first()/last()now return values instead ofOptions.Metadatatype. The datetime rebase resolution reads it directly, and the shuffle schema cache's size estimate useslen()instead ofcapacity().fb_to_schemais deprecated. The shuffle decoder usestry_fb_to_schema, so an invalid schema message now returns a decode error where it used to panic.FFI_ArrowSchema::with_metadatais nowunsafe. The call inmove_to_sparkis sound because the schema was just built byTryFrom.HashJoinExec::with_dynamic_filter_exprandSortExec::with_dynamic_filter_exprare deprecated with no replacement, and Comet no longer calls them.SortExecwith a fetch creates for itself (dynamic_expressions_produced()) and hands it to the Parquet reader below the sort.DynamicFilterJoinExecreports toHashJoinExec::handle_child_pushdown_resultwhat DataFusion'sFilterPushdownrule would, namely that the probe-side self filter was pushed down. The join then installs the filter itself, after finding Comet's consumer in its probe subtree.#[allow(deprecated)]:ExecutionPlan::with_preserve_order, which DataFusion no longer calls.MetricOwningExeckeeps forwarding it.ParquetAccessPlan::into_overall_row_selection, in threedelta_dv.rstests that model the reader's file-level selection peak. DataFusion now keeps row-group-local entries, so the deletion-vector admission bound should be rechecked against the new reader.normalize_spark_empty_key_metadata_rejects_other_malformed_encodings: Arrow 60 accepts empty entries in unsorted Variant dictionaries (Addproptestfuzzing to parquet-variant and implement fixes for findings arrow-rs#10352).make_map_cincomet-test-udfs: arrow 60'sMapBuildernames the map childrenkey/valueby default, so the test UDF now names themkeys/valuesexplicitly to keep exercising non-canonical names.datafusion-spark'sSparkXxhash64now ignores the hidden children of a NULL struct (fix: xxhash64 of a NULL struct ignores the struct fields datafusion#25774) and keeps the running hash for nested dictionaries (fix: keep the running hash for nested dictionaries in Spark xxhash64 datafusion#25813). Three tests inxxhash64_diff.rsthat pinned those differences now assert equality. Comet still keeps its own kernel for those types, so widening the routing is a possible follow-up.Known issue: all-NaN float and double columns in Iceberg manifests
Parquet 60 writes NaN min and max statistics for a column chunk that holds only NaN, and iceberg-rust copies them into the manifest bounds, where iceberg-java records none.
CometIcebergWriteActionSuite"native acceleration: NaN float/double manifest metrics match the JVM writer" caught it, so this PR ignores that test, links #7242 and lists the issue under the Iceberg known issues and in a new 1.3.0 section of the upgrade guide. Re-enable the test once iceberg-rust skips NaN bounds.Known issue: invalid UTF-8 in nested BINARY values read as strings
apache/datafusion#25193 made DataFusion's Parquet file-schema coercion recurse into nested types, so a nested BINARY field that the read schema declares as a string is decoded straight into
Utf8. The parquet reader validates UTF-8 only for columns with theUTF8annotation, so an invalid value produces an unvalidatedStringArray: a panic in debug builds, and unsound data in release builds. Onmain, #7106 decodes these values to U+FFFD. This PR ignores #7106's Rust test (nested_arrow_binary_types_read_as_string_decode_invalid_utf8) and JVM test (ParquetReadSuite"native scan decodes invalid UTF-8 in nested BINARY read as string"). The issue is tracked in #7469 and reported upstream as apache/datafusion#27065, which this PR needs fixed before it merges.DataFusion behavior changes checked against Comet
floor/ceilreturn types and the result ofmap_extractfor absent keys changed. Comet registers its ownfloor,ceilandmap_extract, so neither change reaches Comet.Not included (possible follow-ups)
proptestfuzzing to parquet-variant and implement fixes for findings arrow-rs#10352, so the encoded-metadata decoding and the empty-key retry (canonicalize_spark_empty_key_metadata) can now be removed.stackonce feat: support Spark-compatiblestackfunction datafusion#26266 is in the pinned revision. It is now (6489d15).How are these changes tested?
Run locally on macOS aarch64, at the current head of this branch:
cargo fmt --checkandcargo clippy --all-targets --workspace -- -D warningsare clean, andcargo check -p datafusion-comet --all-targets --features contrib-delta,contrib-lancebuilds.cargo test --workspaceinnative/: 2767 passed, 0 failed, 21 ignored (including the Native Parquet scan reads invalid UTF-8 in nested BINARY values as unvalidated strings on DataFusion 56 #7469 test).makebuilds the native library and the JVM modules.run-all-spark-profiles,run-spark-4.1-testsandrun-iceberg-testslabels.