otterc opened a new pull request, #803:
URL: https://github.com/apache/spark-kubernetes-operator/pull/803

   ### What changes were proposed in this pull request?
   
   When the operator builds the driver pod spec by invoking Spark's driver 
feature steps directly, `BasicDriverFeatureStep` sets `SPARK_USER` via 
`Utils.getCurrentUserName()`. In `spark-submit`, `SparkSubmit` wraps `runMain` 
in `proxyUser.doAs(...)`, so that call returns the proxy user; the operator has 
no equivalent wrapper, so `SPARK_USER` ends up as the operator's identity 
rather than the effective one. This affects `SparkContext.sparkUser`, Spark UI 
ACLs, and external authorization integrations that key off `SPARK_USER`.
   
   Override `SPARK_USER` on the driver container after the feature steps run 
when a proxy user is configured on the driver conf.
   
   ### Why are the changes needed?
   Explained above.
   
   
   ### Does this PR introduce _any_ user-facing change?
   Yes.
   
   
   ### How was this patch tested?
   Unit tests
   
   
   ### Was this patch authored or co-authored using generative AI tooling?
   Generated-by: Claude Code (Claude Opus 4.7)
   


-- 
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]

Reply via email to