cloud-fan commented on a change in pull request #32033:
URL: https://github.com/apache/spark/pull/32033#discussion_r607001427
##########
File path: core/src/main/scala/org/apache/spark/MapOutputTracker.scala
##########
@@ -953,13 +960,19 @@ private[spark] object MapOutputTracker extends Logging {
case DIRECT =>
deserializeObject(bytes, 1, bytes.length -
1).asInstanceOf[Array[MapStatus]]
case BROADCAST =>
- // deserialize the Broadcast, pull .value array out of it, and then
deserialize that
- val bcast = deserializeObject(bytes, 1, bytes.length - 1).
- asInstanceOf[Broadcast[Array[Byte]]]
- logInfo("Broadcast mapstatuses size = " + bytes.length +
- ", actual size = " + bcast.value.length)
- // Important - ignore the DIRECT tag ! Start from offset 1
- deserializeObject(bcast.value, 1, bcast.value.length -
1).asInstanceOf[Array[MapStatus]]
+ try {
+ // deserialize the Broadcast, pull .value array out of it, and then
deserialize that
+ val bcast = deserializeObject(bytes, 1, bytes.length - 1).
+ asInstanceOf[Broadcast[Array[Byte]]]
+ logInfo("Broadcast mapstatuses size = " + bytes.length +
+ ", actual size = " + bcast.value.length)
+ // Important - ignore the DIRECT tag ! Start from offset 1
+ deserializeObject(bcast.value, 1, bcast.value.length -
1).asInstanceOf[Array[MapStatus]]
+ } catch {
+ case e: IOException =>
+ logWarning("Exception encountered during deserializing broadcasted
map statuses: ", e)
+ throw new SparkException("Unable to deserialize broadcasted map
statuses", e)
Review comment:
ah I see, thanks for the explanation!
--
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:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]