Github user nongli commented on a diff in the pull request:
https://github.com/apache/spark/pull/11534#discussion_r55471546
--- Diff:
core/src/main/scala/org/apache/spark/storage/memory/MemoryStore.scala ---
@@ -34,13 +35,15 @@ private case class MemoryEntry(value: Any, size: Long,
deserialized: Boolean)
* Stores blocks in memory, either as Arrays of deserialized Java objects
or as
* serialized ByteBuffers.
*/
-private[spark] class MemoryStore(blockManager: BlockManager,
memoryManager: MemoryManager)
- extends BlockStore(blockManager) {
+private[spark] class MemoryStore(
+ conf: SparkConf,
+ blockManager: BlockManager,
+ memoryManager: MemoryManager)
+ extends Logging {
// Note: all changes to memory allocations, notably putting blocks,
evicting blocks, and
// acquiring or releasing unroll memory, must be synchronized on
`memoryManager`!
- private val conf = blockManager.conf
private val entries = new LinkedHashMap[BlockId, MemoryEntry](32, 0.75f,
true)
--- End diff --
Hmm okay. DiskStore also needs to be thread safe right? It just happens it
doesn't maintain any state right now that's interesting. I think it's worth
commenting so people modifying this know what the expected properties are.
---
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]