[SPARK-62387][R] Drop SparkR support #60913
All Vouch review confidence checks passed
Residual risk 0.17 = Change Risk (0.43) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.43 · 399 lines diff across 4 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.358
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #60913"
general
weight: 0.35
spark-test
What changes were proposed in this pull request?
This PR removes SparkR from Apache Spark 5.0.0: the R package,
bin/sparkR, the JVM-side R backend and ML wrappers, the R paths in spark-submit, YARN and Kubernetes, and related build, CI and docs.These parts are not plain deletions:
.R/.rfiles,sparkr-shellandsparkr-shell-main(sent by the 4.xbin/sparkR) with an error instead of treating them as jars.docker-image-tool.sh -Ralso fails.RMainAppResourceandConstants.APP_RESOURCE_TYPE_R(Kubernetes,@Stable @DeveloperApi) are kept as@deprecated, andKubernetesDriverBuilderrejects anRMainAppResourcebefore any feature step runs. apache/spark-kubernetes-operator createsRMainAppResourcefor thesparkRFilesfield, so deleting the class would break the operator's build on Spark 5.0.spark-rm/Dockerfile.basekeeps R, because the release workflow uses master's copy of it for branch-4.x, which still ships SparkR.spark.sql.execution.arrow.sparkr.enabledis not added toremovedSQLConfigs, so a leftovertruedoes not fail jobs.Why are the changes needed?
The [VOTE] "Deprecate SparkR" called on 2024-08-21 asked to "deprecate the SparkR module in Apache Spark with the upcoming Spark 4 release and remove it in the next major release Spark 5". It passed on 2024-08-26 with 19 +1 votes (12 binding), no 0 and no -1.
SPARK-49347 deprecated SparkR in 4.0.0, and this PR does the removal for Spark 5. sparklyr is the recommended way to use Spark from R.
Does this PR introduce _any_ user-facing change?
Yes, compared to Spark 4.x. There is no SparkR package,
bin/sparkR, or R API docs.spark-submit app.Rfails withR applications are not supported: SparkR was removed in Apache Spark 5.0.0. Spark K8s operator apps that usesparkRFilesfail at submission once the operator runs on Spark 5.0. The core migration guide has a new 5.0 entry.This PR is for master (5.0.0) only. It should not be backported to branch-4.x, where SparkR is deprecated but still supported.
How was this patch tested?
New tests:
SparkSubmitSuite"SPARK-62387: reject R applications":app.R,app.r,sparkr-shellandsparkr-shell-mainare rejected.DriverCommandFeatureStepSuite"SPARK-62387: reject R resource" andKubernetesDriverBuilderSuite"SPARK-62387: reject R applications before any feature step uploads files": the second also checks that no local file is uploaded, with and withoutDriverCommandFeatureStepexcluded.PR CI does not run the release scripts. Their changes were checked with
bash -nand sample version strings. After merge, the scheduled release dry run on master runs the tag and package steps, but not the upload step that holds thecp SparkRguard.Was this patch authored or co-authored using generative AI tooling?
Generated-by: Claude Code (Opus 5.5)