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

    https://github.com/apache/spark/pull/10534#discussion_r48688012
  
    --- Diff: core/src/main/scala/org/apache/spark/MapOutputTracker.scala ---
    @@ -291,17 +289,10 @@ private[spark] class MapOutputTrackerMaster(conf: 
SparkConf)
       // can be read locally, but may lead to more delay in scheduling if 
those locations are busy.
       private val REDUCER_PREF_LOCS_FRACTION = 0.2
     
    -  /**
    -   * Timestamp based HashMap for storing mapStatuses and cached serialized 
statuses in the driver,
    -   * so that statuses are dropped only by explicit de-registering or by 
TTL-based cleaning (if set).
    -   * Other than these two scenarios, nothing should be dropped from this 
HashMap.
    -   */
    -  protected val mapStatuses = new TimeStampedHashMap[Int, 
Array[MapStatus]]()
    -  private val cachedSerializedStatuses = new TimeStampedHashMap[Int, 
Array[Byte]]()
    -
    -  // For cleaning up TimeStampedHashMaps
    -  private val metadataCleaner =
    -    new MetadataCleaner(MetadataCleanerType.MAP_OUTPUT_TRACKER, 
this.cleanup, conf)
    +  // HashMaps for storing mapStatuses and cached serialized statuses in 
the driver.
    +  // Statuses are dropped only by explicit de-registering.
    +  protected val mapStatuses = new HashMap[Int, Array[MapStatus]]()
    --- End diff --
    
    I think that these need to be ConcurrentHashMaps in order to preserve the 
old code's thread-safety guarantees.


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