Skip to content

[FEATURE] Make the RangerSparkExtension compatible with spark-connect #7454

@hit2024

Description

@hit2024

Code of Conduct

Search before asking

  • I have searched in the issues and found no similar issues.

Describe the feature

Currently the RangerSparkExtension checks for kyuubi.session.user for getting the user name from SparkContext. Need to add a fallback to check for spark.connect.session.user if the above is null

Motivation

Using spark-connect and Ranger for the RBAC, need this to identify the user.

Describe the solution

Similar to how we check kyuubi.session.user, we would also check spark.connect.session.user

Additional context

PR for propagating spark.connect.session.user from SparkConnect - https://github.com/apache/spark/pull/55917/changes

Are you willing to submit PR?

  • Yes. I would be willing to submit a PR with guidance from the Kyuubi community to improve.
  • No. I cannot submit a PR at this time.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions