Github user pwendell commented on a diff in the pull request:

    https://github.com/apache/spark/pull/2929#discussion_r19382312
  
    --- Diff: 
core/src/main/scala/org/apache/spark/network/nio/NioBlockTransferService.scala 
---
    @@ -95,16 +95,21 @@ final class NioBlockTransferService(conf: SparkConf, 
securityManager: SecurityMa
         future.onSuccess { case message =>
           val bufferMessage = message.asInstanceOf[BufferMessage]
           val blockMessageArray = 
BlockMessageArray.fromBufferMessage(bufferMessage)
    -
    -      for (blockMessage <- blockMessageArray) {
    -        if (blockMessage.getType != BlockMessage.TYPE_GOT_BLOCK) {
    -          listener.onBlockFetchFailure(
    -            new SparkException(s"Unexpected message 
${blockMessage.getType} received from $cmId"))
    -        } else {
    -          val blockId = blockMessage.getId
    -          val networkSize = blockMessage.getData.limit()
    -          listener.onBlockFetchSuccess(
    -            blockId.toString, new 
NioByteBufferManagedBuffer(blockMessage.getData))
    +      // SPARK-4064: In some cases(eg. Remote block was removed) 
blockMessageArray may be empty.
    +      if (blockMessageArray.isEmpty) {
    +        listener.onBlockFetchFailure(
    +          new SparkException(s"Not received data from $cmId"))
    --- End diff --
    
    Can this say "Received empty message from $cmId" or "Received no data from 
$cmId"?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to