Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPARK-51250][K8S] Add Support for K8s PriorityClass Configuration fo… #49998

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

zemin-piao
Copy link

What changes were proposed in this pull request?

  • Introduce a new spark configuration spark.kubernetes.priorityclass.name.
  • Create a new FeatureStep class PriorityClassFeatureStep that passes configured priority class name to driver and executor pods.
  • Tests for PriorityClassFeatureStep.scala

Why are the changes needed?

Currently when running spark on k8s, with spark-submit approach, in order to specify priority class name, the only possible way is to specify in the pod template. In a cluster with numerous priority classes, it means multiple pod template files are to be used, each of which has variant priority class name only.

One could dynamically generate the pod templates based on priority classes, however this introduces additional overhead on user side (e.g. building a process to dynamically generate templates just for priority class name, making sure dynamically generated templates are still valid)

Furthermore, for SPARK on YARN there is a configuration spark.yarn.priority that is flexible and easy to use for users. It is good to achieve the similar level of simplicity for users moving from SPARK on YARN to SPARK on K8s.

Does this PR introduce any user-facing change?

Yes. With this PR, users can use spark.kubernetes.priorityclass.name to specify the priority class name for driver and executor pods.

How was this patch tested?

Tests were added in this pull request

Was this patch authored or co-authored using generative AI tooling?

No

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant