feat: support Iceberg 1.11, audit existing Iceberg diffs for old configs#4840
Draft
mbutrovich wants to merge 7 commits into
Draft
feat: support Iceberg 1.11, audit existing Iceberg diffs for old configs#4840mbutrovich wants to merge 7 commits into
mbutrovich wants to merge 7 commits into
Conversation
…g that label now re-triggers the pipeline instead of short-circuiting at preflight.
Contributor
Author
|
9 failed tests from Iceberg 1.11 is not bad at all. I will take a look tomorrow. |
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.
Draft while I test.
Which issue does this PR close?
Closes #4381.
Rationale for this change
Iceberg 1.11.0 is the first Iceberg release to support Spark 4.1, and it publishes a real
iceberg-spark-runtime-4.1artifact. Until now we tested Iceberg only against Spark 3.4/3.5, so the Spark 4.1 path went uncovered. This adds an Iceberg 1.11 / Spark 4.1 target so we can catch compatibility issues in that configuration.Iceberg 1.11 also removed the legacy upstream Comet reader classes (the ones the older diffs had to delete), so the diff needed to enable Comet in Iceberg's own tests shrinks dramatically to just enabling Comet in the test session builders.
What changes are included in this PR?
spark/pom.xml: the spark-4.1 profile now depends on the realiceberg-spark-runtime-4.1_2.13:1.11.0instead of reusing the 4.0 runtime, soCometIcebergNativeSuiteruns against genuine Spark 4.1 Iceberg.dev/diffs/iceberg/1.11.0.diff: new diff generated against theapache-iceberg-1.11.0tag. Adds thecometversion, wires Comet intobuild.gradle, and injects the Comet plugin / shuffle manager config into thespark/v4.1test bases. Because 1.11 removed the legacy Comet integration entirely, upstream no longer provides a Comet dependency, so the diff adds it astestImplementationin theiceberg-sparkandiceberg-spark-extensionsmodules (plusintegrationImplementationiniceberg-spark-runtime); without these the test JVMs fail to loadCometPlugin. No class deletions or reader edits are needed. Includes the newTestVariantShreddingbase (variant shredding is new in 1.11 and builds its own session).spark/src/main/scala/org/apache/comet/iceberg/IcebergReflection.scala: Iceberg 1.11 renamed twoSparkScanaccessors the native scan reflects on (expectedSchema()->projection(),filterExpressions()->filters()). Without this the reflection returnedNoneand every Iceberg read silently fell back to Spark. Both use a new-name-then-old-name lookup so one build still supports Iceberg 1.8-1.11.spark/src/test/scala/org/apache/comet/CometIcebergNativeSuite.scala: tests that exercise the native scan now assert it actually engages (CometIcebergNativeScanExecpresent) instead of only checking results, so a silent fallback like the one above can't pass green again. Intentional-fallback tests assert the fallback with its reason.iceberg_1_11runs on every PR (our only Spark 4.1 Iceberg coverage) andiceberg_1_10is demoted to main-only. A newrun-iceberg-testsPR label enables the main-only Iceberg jobs (1.8/1.9/1.10) on a PR; the label is added to the preflight gate so applying it actually re-triggers the pipeline.spark.comet.schemaEvolution.enabledandspark.comet.exec.broadcastExchange.enabled(both gone fromCometConf), andspark.comet.use.lazyMaterialization(no-op for the Iceberg native scan).How are these changes tested?
Existing Iceberg Spark test suites (
iceberg-spark,iceberg-spark-extensions,iceberg-spark-runtime) run with Comet enabled via the newiceberg_1_11CI job against Spark 4.1.CometIcebergNativeSuiteexercises the native Iceberg scan against the real 4.1 runtime.CI coverage across Spark and Iceberg versions (rows are the Spark version; columns are the Iceberg runtime paired with it):
run-iceberg-testsrun-iceberg-testsrun-iceberg-testsComet suites =
CometIcebergNativeSuite(and the other Iceberg-touching Comet unit suites) in thepr_build_linux"scans" bucket; the Iceberg runtime is pulled by the activespark-*profile inspark/pom.xml. Runs on every PR across all five Spark profiles.Iceberg tests = Apache Iceberg's own
iceberg-spark/-extensions/-runtimesuites run with Comet enabled, via theiceberg_1_8/iceberg_1_9/iceberg_1_10/iceberg_1_11jobs. 1.11 (Spark 4.1) runs on every PR; the older three run on push-to-main or on a PR labeledrun-iceberg-tests.The
projection()/filters()rename is only in Iceberg 1.11'sspark/v4.1, so 4.1 x 1.11 is the only cell that exercises the new accessor names; every other Comet-suite cell exercises the old-name fallback, so backward compatibility is covered on every PR.