[GitHub] srowen commented on a change in pull request #23580: [SPARK-26660]Add warning logs when broadcasting large task binary

2019-01-27 Thread GitBox
srowen commented on a change in pull request #23580: [SPARK-26660]Add warning 
logs when broadcasting large task binary
URL: https://github.com/apache/spark/pull/23580#discussion_r251302189
 
 

 ##
 File path: core/src/main/scala/org/apache/spark/scheduler/DAGScheduler.scala
 ##
 @@ -1162,6 +1162,10 @@ private[spark] class DAGScheduler(
 partitions = stage.rdd.partitions
   }
 
+  if (taskBinaryBytes.length * 1000 > TaskSetManager.TASK_SIZE_TO_WARN_KB) 
{
 
 Review comment:
   Yeah should have looked at the test logs, my fault.
   1000 = KB, 1024 = KiB. This should be correct unless the constant is misnamed


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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



[GitHub] srowen commented on a change in pull request #23580: [SPARK-26660]Add warning logs when broadcasting large task binary

2019-01-21 Thread GitBox
srowen commented on a change in pull request #23580: [SPARK-26660]Add warning 
logs when broadcasting large task binary
URL: https://github.com/apache/spark/pull/23580#discussion_r249470431
 
 

 ##
 File path: core/src/main/scala/org/apache/spark/scheduler/DAGScheduler.scala
 ##
 @@ -1162,6 +1162,12 @@ private[spark] class DAGScheduler(
 partitions = stage.rdd.partitions
   }
 
+  val taskBinarySizeKb = 
Utils.byteStringAsKb(s"${taskBinaryBytes.length}b")
+
+  if (taskBinarySizeKb > TaskSetManager.TASK_SIZE_TO_WARN_KB) {
 
 Review comment:
   This seems OK. So it's warning about broadcasts, not just task size?
   Rather than convert to KB and back, why not compare taskBinaryBytes.length * 
1000 vs TASK_SIZE_TO_WARN_KB here and avoid the conversion back below? 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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