Package com.linkedin.davinci.store.cache
Class VeniceStoreCacheStorageEngine
- java.lang.Object
-
- com.linkedin.davinci.store.AbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
- com.linkedin.davinci.store.cache.VeniceStoreCacheStorageEngine
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
public class VeniceStoreCacheStorageEngine extends AbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.linkedin.davinci.store.AbstractStorageEngine
AbstractStorageEngine.StoragePartitionAdjustmentTrigger
-
-
Field Summary
-
Fields inherited from class com.linkedin.davinci.store.AbstractStorageEngine
METADATA_PARTITION_ID
-
-
Constructor Summary
Constructors Constructor Description VeniceStoreCacheStorageEngine(java.lang.String storeVersionName, ObjectCacheConfig config, org.apache.avro.Schema keySchema, com.github.benmanes.caffeine.cache.AsyncCacheLoader asyncCacheLoader)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description VeniceStoreCacheStoragePartition
createStoragePartition(StoragePartitionConfig partitionConfig)
VeniceStoreCache
getCache()
AbstractStoragePartition
getPartitionOrThrow(int partitionId)
java.util.Set<java.lang.Integer>
getPersistedPartitionIds()
java.util.concurrent.locks.ReadWriteLock
getRWLockForPartitionOrThrow(int partitionId)
Making it public is for testing purpose.long
getStoreSizeInBytes()
PersistenceType
getType()
<K,V>
voidputDeserializedValue(K key, V value)
-
Methods inherited from class com.linkedin.davinci.store.AbstractStorageEngine
addStoragePartition, addStoragePartition, adjustStoragePartition, beginBatchWrite, checkDatabaseIntegrity, clearPartitionOffset, clearStoreVersionState, close, closeMetadataPartition, closePartition, containsPartition, createSnapshot, delete, deleteWithReplicationMetadata, drop, dropMetadataPartition, dropPartition, endBatchWrite, get, get, get, getByKeyPrefix, getCachedRMDSizeInBytes, getCachedStoreSizeInBytes, getCompressionStrategy, getIterator, getMetadataPartition, getNumberOfPartitions, getPartitionIds, getPartitionOffset, getPartitionSizeInBytes, getReplicationMetadata, getRMDSizeInBytes, getStoreVersionName, getStoreVersionState, hasMemorySpaceLeft, isChunked, isClosed, isMetadataPartition, put, put, put, putPartitionOffset, putReplicationMetadata, putStoreVersionState, putWithReplicationMetadata, reopenStoragePartition, restoreStoragePartitions, restoreStoragePartitions, suppressLogs, sync, toString, updateStoreVersionStateCache
-
-
-
-
Constructor Detail
-
VeniceStoreCacheStorageEngine
public VeniceStoreCacheStorageEngine(java.lang.String storeVersionName, ObjectCacheConfig config, org.apache.avro.Schema keySchema, com.github.benmanes.caffeine.cache.AsyncCacheLoader asyncCacheLoader)
-
-
Method Detail
-
getType
public PersistenceType getType()
- Specified by:
getType
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
getStoreSizeInBytes
public long getStoreSizeInBytes()
- Specified by:
getStoreSizeInBytes
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
getPersistedPartitionIds
public java.util.Set<java.lang.Integer> getPersistedPartitionIds()
- Specified by:
getPersistedPartitionIds
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
createStoragePartition
public VeniceStoreCacheStoragePartition createStoragePartition(StoragePartitionConfig partitionConfig)
- Specified by:
createStoragePartition
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
getPartitionOrThrow
public AbstractStoragePartition getPartitionOrThrow(int partitionId)
- Overrides:
getPartitionOrThrow
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
getRWLockForPartitionOrThrow
public java.util.concurrent.locks.ReadWriteLock getRWLockForPartitionOrThrow(int partitionId)
Description copied from class:AbstractStorageEngine
Making it public is for testing purpose.- Overrides:
getRWLockForPartitionOrThrow
in classAbstractStorageEngine<VeniceStoreCacheStoragePartition>
-
putDeserializedValue
public <K,V> void putDeserializedValue(K key, V value)
-
getCache
public VeniceStoreCache getCache()
-
-