sam-1112 opened a new pull request, #7778: URL: https://github.com/apache/datafusion-comet/pull/7778
## Which issue does this PR close? Closes #6956. Related: [#7493 — Support Iceberg 1.12.0 and run the Iceberg suites on Spark 4.2](https://github.com/apache/datafusion-comet/issues/7493). ## Rationale for this change Iceberg tables using `write.object-storage.enabled=true` currently fall back to the JVM writer. Support Iceberg's built-in object storage layout so more existing table configurations can use Comet's native Iceberg writer. This change makes no throughput or query latency claim. ## What changes are included in this PR? - Resolve the instantiated default or object storage provider on the driver. Use its resolved root, nullable context and partition-path setting for eligibility, FileIO, credentials and serde. The shared `getDataLocation` helper remains unchanged; write-side callers no longer treat the hash of an empty filename as a root. - Add `IcebergObjectStorageLayout` at `IcebergWriteCommon` field 12. Message presence selects the layout, with explicit boolean presence and nullable context preserved. - Generate the Java-compatible partition path before hashing UTF-8 bytes with the existing Iceberg Murmur3 helper. Keep the low 20 bits as 4/4/4/8 binary entropy, including the filename prefix case when context is null and partition paths are disabled. - Keep unpartitioned, fanout and clustered writers on the same tracked generator, preserving attempt filenames and abort/commit-failure cleanup. - Add shared Java oracle fixtures, reflection and payload tests, writer selection and parity tests, rolling and physical cleanup checks, and update user and contributor documentation. The supported and integration-verified scope of this PR is Spark 3.5 / Iceberg 1.8.1, Spark 4.0 / 1.10.0 and Spark 4.1 / 1.11.0. Legacy location properties retain the linked Java provider's precedence and rejection behavior. No Spark 3.4 or Base64 entropy layout is added. Spark 4.2 runtime compatibility and end-to-end verification are deferred to #7493. The existing 4.2 test guard remains in place. After the relevant #7493 fixes land in `main` and a compatible runtime is available, rerun the four suites below on Spark 4.2. A follow-up layout fix is needed only if those tests expose a layout-specific problem; otherwise update the support matrix and validation record. This PR does not claim Spark 4.2 native-write support. Custom providers and inaccessible layouts still fall back, as do unsupported storage schemes, FileIO, authentication, encryption, types and writer settings. This does not enable HDFS writes, change writer defaults, add a required Comet config, change the iceberg-rust pin or add a dependency. New JVM layout descriptions are `IcebergReflection.WriteLocationLayout` and `IcebergReflection.ObjectStorageLayout`; no public configuration keys change. ## How are these changes tested? The real Java providers at Iceberg 1.8.1, 1.10.0 and 1.11.0 generate the same 108 shared fixtures. `dev/IcebergObjectStorageFixtures.java` records expected paths independently of the Rust code. The root reactor ran these four suites on each verified profile: `IcebergReflectionSuite`, `IcebergWriteProtoTranslationSuite`, `CometIcebergWriteDetectionSuite` and `CometIcebergWriteActionSuite`. | Spark profile | Iceberg | Passed | Canceled | Meaning | | ------------- | ------- | ------ | -------- | -------------------------------------------------- | | 3.5 | 1.8.1 | 284 | 14 | integration passed; version-specific cancellations | | 4.0 | 1.10.0 | 295 | 3 | integration passed; version-specific cancellations | | 4.1 | 1.11.0 | 298 | 0 | integration passed | A separate Spark 4.2 attempt compiled successfully and passed 63 tests, with 235 cases canceled by the existing guard. Its borrowed Iceberg Spark 4.0 runtime (1.10.0) has the known `SparkView` / `View` binary incompatibility. These are compile and unit-check results, not a Spark 4.2 write integration verdict; the canceled cases remain follow-up validation under #7493. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
