gengliangwang commented on code in PR #46494:
URL: https://github.com/apache/spark/pull/46494#discussion_r1599208898
##########
core/src/main/scala/org/apache/spark/broadcast/TorrentBroadcast.scala:
##########
@@ -278,11 +278,12 @@ private[spark] class TorrentBroadcast[T: ClassTag](obj:
T, id: Long, serializedO
}
case None =>
val estimatedTotalSize = Utils.bytesToString(numBlocks.toLong *
blockSize)
- logInfo(s"Started reading broadcast variable $id with $numBlocks
pieces " +
- s"(estimated total size $estimatedTotalSize)")
+ logInfo(log"Started reading broadcast variable ${MDC(BROADCAST_ID,
id)} with ${MDC(NUM_BROADCAST_BLOCK, numBlocks)} pieces " +
+ log"(estimated total size ${MDC(NUM_BYTES,
estimatedTotalSize)})")
val startTimeNs = System.nanoTime()
val blocks = readBlocks()
- logInfo(s"Reading broadcast variable $id took
${Utils.getUsedTimeNs(startTimeNs)}")
+ logInfo(log"Reading broadcast variable ${MDC(BROADCAST_ID, id)}" +
+ log" took ${MDC(TOTAL_TIME, Utils.getUsedTimeNs(startTimeNs))}
ms")
Review Comment:
This is NS instead of ms
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]