Class/Object

org.apache.spark.memory

SnappyUnifiedMemoryManager

Related Docs: object SnappyUnifiedMemoryManager | package memory

Permalink

class SnappyUnifiedMemoryManager extends UnifiedMemoryManager with StoreUnifiedManager with StoreCallback

When there is request for execution or storage memory, critical up and eviction up events are checked. If they are set, try to free the memory cached by Spark rdds by calling memoryStore.evictBlocksToFreeSpace. If enough memory cannot be freed, return the call and let Spark take a corrective action. In such cases Spark either fails the task or move the current RDDs data to disk. If the critical and eviction events are not set, it asks the UnifiedMemoryManager to allocate the space.

Self Type
SnappyUnifiedMemoryManager
Linear Supertypes
StoreCallback, Serializable, Serializable, StoreUnifiedManager, UnifiedMemoryManager, MemoryManager, internal.Logging, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SnappyUnifiedMemoryManager
  2. StoreCallback
  3. Serializable
  4. Serializable
  5. StoreUnifiedManager
  6. UnifiedMemoryManager
  7. MemoryManager
  8. Logging
  9. AnyRef
  10. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new SnappyUnifiedMemoryManager(conf: SparkConf, numCores: Int)

    Permalink
  2. new SnappyUnifiedMemoryManager(conf: SparkConf, numCores: Int, tempManager: Boolean = false)

    Permalink

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. def acquireStorageMemory(blockId: BlockId, numBytes: Long, memoryMode: MemoryMode): Boolean

    Permalink

    Acquire N bytes of memory to cache the given block, evicting existing ones if necessary.

    Acquire N bytes of memory to cache the given block, evicting existing ones if necessary.

    returns

    whether all N bytes were successfully granted.

    Definition Classes
    SnappyUnifiedMemoryManager → UnifiedMemoryManager → MemoryManager
  5. def acquireStorageMemoryForObject(objectName: String, blockId: BlockId, numBytes: Long, memoryMode: MemoryMode, buffer: UMMMemoryTracker, shouldEvict: Boolean): Boolean

    Permalink
  6. def acquireUnrollMemory(blockId: BlockId, numBytes: Long, memoryMode: MemoryMode): Boolean

    Permalink

    Acquire N bytes of memory to unroll the given block, evicting existing ones if necessary.

    Acquire N bytes of memory to unroll the given block, evicting existing ones if necessary.

    This extra method allows subclasses to differentiate behavior between acquiring storage memory and acquiring unroll memory. For instance, the memory management model in Spark 1.5 and before places a limit on the amount of space that can be freed from unrolling.

    returns

    whether all N bytes were successfully granted.

    Definition Classes
    UnifiedMemoryManager → MemoryManager
  7. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  8. def assertInvariants(): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    UnifiedMemoryManager
  9. val bootManager: Boolean

    Permalink
  10. def changeOffHeapOwnerToStorage(buffer: ByteBuffer, allowNonAllocator: Boolean): Unit

    Permalink

    Change the off-heap owner to mark it being used for storage.

    Change the off-heap owner to mark it being used for storage. Passing the owner as null allows moving ByteBuffers not allocated by BufferAllocators to be also changed and freshly accounted.

    Definition Classes
    SnappyUnifiedMemoryManagerStoreUnifiedManager
  11. def clear(): Unit

    Permalink

    Clears the internal map

    Clears the internal map

    Definition Classes
    SnappyUnifiedMemoryManagerStoreUnifiedManager
  12. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  13. def close(): Unit

    Permalink

    This method will be called if executor is going to be restarted.

    This method will be called if executor is going to be restarted. When executor is coming up all accounting from store will be done in bootMemoryManager. When executor stops we will copy the existing entry in this manager to boot manager. Once executor comes back again we will again copy the boot manager entries to run time manager.

    Definition Classes
    SnappyUnifiedMemoryManagerStoreUnifiedManager
  14. def dropStorageMemoryForObject(name: String, memoryMode: MemoryMode, ignoreNumBytes: Long): Long

    Permalink
  15. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  16. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  17. final def executionMemoryUsed: Long

    Permalink

    Execution memory currently in use, in bytes.

    Execution memory currently in use, in bytes.

    Definition Classes
    MemoryManager
  18. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  19. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  20. def getExecutionPoolSize(memoryMode: MemoryMode): Long

    Permalink
  21. def getExecutionPoolUsedMemory(memoryMode: MemoryMode): Long

    Permalink
  22. def getOffHeapMemory(objectName: String): Long

    Permalink
  23. def getStoragePoolMemoryUsed(memoryMode: MemoryMode): Long

    Permalink
  24. def getStoragePoolSize(memoryMode: MemoryMode): Long

    Permalink
  25. def hasOffHeap: Boolean

    Permalink
  26. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  27. def init(): Unit

    Permalink

    Initializes the memoryManager

    Initializes the memoryManager

    Definition Classes
    SnappyUnifiedMemoryManagerStoreUnifiedManager
  28. def initMemoryStats(stats: MemoryManagerStats): Unit

    Permalink
  29. def initializeLogIfNecessary(isInterpreter: Boolean, silent: Boolean = false): Boolean

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  30. def initializeLogIfNecessary(isInterpreter: Boolean): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  31. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  32. def isTraceEnabled(): Boolean

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  33. def log: Logger

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  34. def logDebug(msg: ⇒ String, throwable: Throwable): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  35. def logDebug(msg: ⇒ String): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  36. def logError(msg: ⇒ String, throwable: Throwable): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  37. def logError(msg: ⇒ String): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  38. def logInfo(msg: ⇒ String, throwable: Throwable): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  39. def logInfo(msg: ⇒ String): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  40. def logName: String

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  41. def logStats(tag: String): Unit

    Permalink
  42. def logStats(): Unit

    Permalink
  43. def logTrace(msg: ⇒ String, throwable: Throwable): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  44. def logTrace(msg: ⇒ String): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  45. def logWarning(msg: ⇒ String, throwable: Throwable): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  46. def logWarning(msg: ⇒ String): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Logging
  47. val maxHeapMemory: Long

    Permalink

    the maximum heap memory that is available for use by MemoryManager; callers should leave out some amount of "reserved memory" for unaccounted object allocations

    the maximum heap memory that is available for use by MemoryManager; callers should leave out some amount of "reserved memory" for unaccounted object allocations

    Definition Classes
    SnappyUnifiedMemoryManager → UnifiedMemoryManager
  48. val maxOffHeapMemory: Long

    Permalink
    Attributes
    protected[this]
    Definition Classes
    MemoryManager
  49. def maxOffHeapStorageMemory: Long

    Permalink

    Total available off heap memory for storage, in bytes.

    Total available off heap memory for storage, in bytes. This amount can vary over time, depending on the MemoryManager implementation.

    Definition Classes
    UnifiedMemoryManager → MemoryManager
  50. def maxOnHeapStorageMemory: Long

    Permalink

    Total available on heap memory for storage, in bytes.

    Total available on heap memory for storage, in bytes. This amount can vary over time, depending on the MemoryManager implementation. In this model, this is equivalent to the amount of memory not occupied by execution.

    Definition Classes
    UnifiedMemoryManager → MemoryManager
  51. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  52. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  53. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  54. val offHeapExecutionMemoryPool: ExecutionMemoryPool

    Permalink
    Attributes
    protected
    Definition Classes
    MemoryManager
  55. val offHeapStorageMemory: Long

    Permalink
    Attributes
    protected[this]
    Definition Classes
    MemoryManager
  56. val offHeapStorageMemoryPool: StorageMemoryPool

    Permalink
    Attributes
    protected
    Definition Classes
    MemoryManager
  57. val onHeapExecutionMemoryPool: ExecutionMemoryPool

    Permalink
    Attributes
    protected
    Definition Classes
    MemoryManager
  58. val onHeapStorageMemoryPool: StorageMemoryPool

    Permalink
    Attributes
    protected
    Definition Classes
    MemoryManager
  59. val pageSizeBytes: Long

    Permalink

    The default page size, in bytes.

    The default page size, in bytes.

    If user didn't explicitly set "spark.buffer.pageSize", we figure out the default value by looking at the number of cores available to the process, and the total amount of memory, and then divide it by a factor of safety.

    Definition Classes
    MemoryManager
  60. final def releaseAllStorageMemory(): Unit

    Permalink

    Release all storage memory acquired.

    Release all storage memory acquired.

    Definition Classes
    MemoryManager
  61. def releaseExecutionMemory(numBytes: Long, taskAttemptId: Long, memoryMode: MemoryMode): Unit

    Permalink

    Release numBytes of execution memory belonging to the given task.

    Release numBytes of execution memory belonging to the given task.

    Definition Classes
    SnappyUnifiedMemoryManager → MemoryManager
  62. def releaseStorageMemory(numBytes: Long, memoryMode: MemoryMode): Unit

    Permalink

    Release N bytes of storage memory.

    Release N bytes of storage memory.

    Definition Classes
    SnappyUnifiedMemoryManager → MemoryManager
  63. def releaseStorageMemoryForObject(objectName: String, numBytes: Long, memoryMode: MemoryMode): Unit

    Permalink
  64. final def releaseUnrollMemory(numBytes: Long, memoryMode: MemoryMode): Unit

    Permalink

    Release N bytes of unroll memory.

    Release N bytes of unroll memory.

    Definition Classes
    MemoryManager
  65. final def setMemoryStore(store: MemoryStore): Unit

    Permalink

    Set the MemoryStore used by this manager to evict cached blocks.

    Set the MemoryStore used by this manager to evict cached blocks. This must be set after construction due to initialization ordering constraints.

    Definition Classes
    MemoryManager
  66. def shouldStopRecovery(): Boolean

    Permalink
  67. final def storageMemoryUsed: Long

    Permalink

    Storage memory currently in use, in bytes.

    Storage memory currently in use, in bytes.

    Definition Classes
    MemoryManager
  68. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  69. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  70. final val tungstenMemoryMode: MemoryMode

    Permalink

    Tracks whether Tungsten memory will be allocated on the JVM heap or off-heap using sun.misc.Unsafe.

    Tracks whether Tungsten memory will be allocated on the JVM heap or off-heap using sun.misc.Unsafe.

    Definition Classes
    MemoryManager
  71. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  72. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  73. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from StoreCallback

Inherited from Serializable

Inherited from Serializable

Inherited from StoreUnifiedManager

Inherited from UnifiedMemoryManager

Inherited from MemoryManager

Inherited from internal.Logging

Inherited from AnyRef

Inherited from Any

Ungrouped