Read JNI metadata from the renamed cuDF Spark artifact - #645
Conversation
|
There was a problem hiding this comment.
🟢 Approval recommended
The functional changes are small and well-covered by new unit tests; remaining feedback is limited to documentation/diagnostic wording clarity.
Pull request overview
This PR updates the RAPIDS-accelerated UDF native dependency resolver to handle the upstream rename of the JNI artifact metadata, while keeping compatibility with previously released jars that still carry the legacy metadata layout.
Changes:
- Prefer
cudf-spark-jni-version-info.propertiesand fall back to legacyspark-rapids-jni-version-info.propertieswhen resolving JNI revision/URL. - Emit
jar.cudf.spark.jni.revisionwhile retainingjar.spark.rapids.jni.revisionas a compatibility alias. - Update UDF documentation and add unit coverage for both the renamed and legacy metadata layouts.
File summaries
| File | Description |
|---|---|
| examples/UDF-Examples/RAPIDS-accelerated-UDFs/resolve-jni-cudf-pins.sh | Adds dual-metadata probing and writes the new JNI revision property while keeping a legacy alias. |
| examples/UDF-Examples/RAPIDS-accelerated-UDFs/test_resolve_jni_cudf_pins.py | New unit tests covering both renamed and legacy jar metadata layouts via a controlled curl stub. |
| examples/UDF-Examples/RAPIDS-accelerated-UDFs/README.md | Documentation updates to reference the renamed artifact and resolver behavior. |
| examples/UDF-Examples/RAPIDS-accelerated-UDFs/pom.xml | Updates Maven diagnostics/comments to reflect the renamed JNI artifact. |
Review details
Suppressed comments (1)
examples/UDF-Examples/RAPIDS-accelerated-UDFs/README.md:170
- This sentence states pins are derived from the "cudf-spark-jni" revision, but for older jars the revision comes from spark-rapids-jni. Consider mentioning the legacy name here too so the documentation matches the resolver behavior.
When changing the rapids-4-spark jar version, rebuild the native UDFs with
matching cuDF/RMM/CCCL headers and libraries. In prebuilt mode, the Maven build
derives those native dependency pins from the `cudf-spark-jni` revision
recorded in the jar. After changing jar versions, remove `target/native-deps`,
- Files reviewed: 4/4 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Update the accelerated UDF native dependency resolver to consume cudf-spark-jni-version-info.properties after the upstream JNI artifact rename. Expose the embedded JNI revision as jar.cudf.spark.jni.revision and update resolver errors, status output, Maven comments, and user documentation to use the cudf-spark-jni name. Do not retain the legacy spark-rapids-jni metadata filename or property alias. Validation: ran the native library extraction unit tests, checked resolver shell syntax, parsed the Maven POM, verified whitespace, and confirmed the changed files contain no legacy JNI references. Reference: NVIDIA/cudf-spark-jni#5093 Signed-off-by: Tim Liu <timl@nvidia.com>
37d4317 to
3dfd72f
Compare

Summary