fix(spark): add default service account fallback for Spark Connect - #672
fix(spark): add default service account fallback for Spark Connect#672amh1k wants to merge 4 commits into
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
🎉 Welcome to the Kubeflow SDK! 🎉 Thanks for opening your first PR! We're happy to have you as part of our community 🚀 Here's what happens next:
Join the community:
Feel free to ask questions in the comments if you need any help or clarification! |
|
/ok-to-test |
| memory=memory, | ||
| template=template, | ||
| ) | ||
|
|
There was a problem hiding this comment.
Please add a pytest parametrized test in utils_test.py to cover all test cases for get_spark_connect_driver_spec.
15bd5ef to
8388173
Compare
| containers=[], | ||
| service_account_name=driver.service_account, | ||
| ) | ||
| # Fallback to the the spark-operator chart's default service account if not specified. |
There was a problem hiding this comment.
Typo in the new comment - "the the spark-operator chart's..." should just be "the spark-operator chart's..."
| "expected_cores": 2, | ||
| "expected_memory": "4g", | ||
| "expected_service_account": "custom-spark-sa", | ||
| }, |
There was a problem hiding this comment.
Would you mind adding one more case where service_account is set but resources is left default?
|
@amh1k Can you please sign your commit to get the DCO check to pass? |
This change introduces a fallback to the `spark-operator-spark` default service account when `driver.service_account` is not explicitly specified in the Spark Connect API. Why this is needed: This simplifies simple SDK use cases on the default operator installation, where manual specification of a service account on the API becomes cumbersome. Note: This is a temporary workaround and includes a TODO comment to ensure it is removed once issue kubeflow#617 is fully resolved. Signed-off-by: amh1k <abdulmoizx97@gmail.com>
Co-authored-by: Tariq Hasan <mmtariquehsn@gmail.com> Signed-off-by: Abdul Moiz Hussain <abdulmoizx97@gmail.com>
Signed-off-by: amh1k <abdulmoizx97@gmail.com>
Signed-off-by: amh1k <abdulmoizx97@gmail.com>
af52c17 to
7ea0e33
Compare
What this PR does / why we need it:
This change introduces a fallback to the
spark-operator-sparkdefault service account whendriver.service_accountis not explicitly specified in the Spark Connect API.This simplifies basic SDK use cases on the default operator installation, where manual specification of a service account on the API becomes cumbersome for end users.
Note: This is a temporary workaround and is meant to be removed once #617 lands.
Which issue(s) this PR fixes (optional, in
Fixes #<issue number>, #<issue number>, ...format, will close the issue(s) when PR gets merged):Fixes #668
Checklist:
make verifylocally to ensure code quality, formatting compliance, and no linting errors.make test-pythonlocally to ensure unit tests pass.