You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/04/01 14:08:32 UTC

[GitHub] [spark] srowen commented on a change in pull request #24261: [SPARK-27192][Core] spark.task.cpus should be less or equal than spark.executor.cores

srowen commented on a change in pull request #24261: [SPARK-27192][Core] spark.task.cpus should be less or equal than spark.executor.cores
URL: https://github.com/apache/spark/pull/24261#discussion_r270884610
 
 

 ##########
 File path: core/src/test/scala/org/apache/spark/scheduler/TaskSchedulerImplSuite.scala
 ##########
 @@ -155,7 +159,9 @@ class TaskSchedulerImplSuite extends SparkFunSuite with LocalSparkContext with B
 
   test("Scheduler correctly accounts for multiple CPUs per task") {
     val taskCpus = 2
-    val taskScheduler = setupScheduler(config.CPUS_PER_TASK.key -> taskCpus.toString)
+    val taskScheduler = setupSchedulerWithMaster(
+      "local[2]",  // for passing CPUS_PER_TASK check in SparkContext
 
 Review comment:
   I don't know if that comment is necessary, and I suppose you could write `s"local[$taskCpus]"` here. But seems OK with me overall.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org