ByteBufferBlockStoreUpdater¶
ByteBufferBlockStoreUpdater
is a BlockStoreUpdater (that BlockManager uses for storing a block from bytes already in memory).
Creating Instance¶
ByteBufferBlockStoreUpdater
takes the following to be created:
- BlockId
- StorageLevel
-
ClassTag
(Scala) -
ChunkedByteBuffer
-
tellMaster
flag (default:true
) -
keepReadLock
flag (default:false
)
ByteBufferBlockStoreUpdater
is created when:
BlockManager
is requested to store a block (bytes) locally
Block Data¶
blockData(): BlockData
blockData
creates a ByteBufferBlockData
(with the ChunkedByteBuffer).
blockData
is part of the BlockStoreUpdater abstraction.
readToByteBuffer¶
readToByteBuffer(): ChunkedByteBuffer
readToByteBuffer
simply gives the ChunkedByteBuffer (it was created with).
readToByteBuffer
is part of the BlockStoreUpdater abstraction.
Storing Block to Disk¶
saveToDiskStore(): Unit
saveToDiskStore
requests the DiskStore (of the parent BlockManager) to putBytes (with the BlockId and the ChunkedByteBuffer).
saveToDiskStore
is part of the BlockStoreUpdater abstraction.