-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-27192][Core] spark.task.cpus should be less or equal than spark.executor.cores #24131
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -140,13 +140,6 @@ class SparkConfSuite extends SparkFunSuite with LocalSparkContext with ResetSyst | |
| assert(sc.appName === "My other app") | ||
| } | ||
|
|
||
| test("creating SparkContext with cpus per tasks bigger than cores per executors") { | ||
|
||
| val conf = new SparkConf(false) | ||
| .set(EXECUTOR_CORES, 1) | ||
| .set(CPUS_PER_TASK, 2) | ||
| intercept[SparkException] { sc = new SparkContext(conf) } | ||
| } | ||
|
|
||
| test("nested property names") { | ||
| // This wasn't supported by some external conf parsing libraries | ||
| System.setProperty("spark.test.a", "a") | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think you need two messages here. Just have one stating that
${CPUS_PER_TASK.key} must be <= the $executorCoreNum cores available per executorThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
executorCoreNumis decided bylocal[N]or--conf spark.executor.cores=M, I think we should info this in exception.And, if user both sets
--master local[N]and--conf spark.executor.cores=M, I think we should ignore the latter.