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

    https://github.com/apache/spark/pull/10705#discussion_r50872433
  
    --- Diff: core/src/main/scala/org/apache/spark/storage/BlockManager.scala 
---
    @@ -403,7 +406,20 @@ private[spark] class BlockManager(
        */
       def getLocal(blockId: BlockId): Option[BlockResult] = {
         logDebug(s"Getting local block $blockId")
    -    doGetLocal(blockId, asBlockResult = 
true).asInstanceOf[Option[BlockResult]]
    +    val res = doGetLocal(blockId, asBlockResult = 
true).asInstanceOf[Option[BlockResult]]
    --- End diff --
    
    A shortened version of this should be a class comment. Describe what 
pinning means and what are the API semantics.
    
    "we should add a pin-counting mechanism to track which blocks/pages are 
being read in order to prevent them from being evicted prematurely. I propose 
to do this in two phases: first, add a safe, conservative approach in which all 
BlockManager.get*() calls implicitly increment the pin count of blocks and 
where tasks' pins are automatically freed upon task completion (this PR)"


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

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

Reply via email to