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

    https://github.com/apache/spark/pull/1507#discussion_r15250406
  
    --- Diff: 
core/src/main/scala/org/apache/spark/storage/BlockFetcherIterator.scala ---
    @@ -154,14 +147,15 @@ object BlockFetcherIterator {
           // Split local and remote blocks. Remote blocks are further split 
into FetchRequests of size
           // at most maxBytesInFlight in order to limit the amount of data in 
flight.
           val remoteRequests = new ArrayBuffer[FetchRequest]
    +      var totalBlocks = 0
           for ((address, blockInfos) <- blocksByAddress) {
    +        totalBlocks += blockInfos.size
             if (address == blockManagerId) {
    -          numLocal = blockInfos.size
    +          readMetrics.localBlocksFetched += blockInfos.size
    --- End diff --
    
    Maybe we don't care about this...but this results in the metrics reporting 
that local blocks have been fetched before they're actually read from disk.  Is 
it too annoying to move this to where the blocks actually get read?


---
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.
---

Reply via email to