java.lang.AutoCloseable
public interface ReadThruProvider
extends java.lang.AutoCloseable
Modifier and Type | Method | Description |
---|---|---|
void |
init(java.util.Map<java.lang.String,java.lang.String> parameters,
java.lang.String cacheId) |
Perform tasks like allocating resources or acquiring connections, etc.
|
ProviderDataStructureItem |
loadDataStructureFromSource(java.lang.String key,
DistributedDataStructureType distributedDataStructureType) |
Responsible for loading the object from the data source.
|
ProviderCacheItem |
loadFromSource(java.lang.String key) |
Responsible for loading the object from the data source.
|
java.util.Map<java.lang.String,ProviderCacheItem> |
loadFromSource(java.util.Collection<java.lang.String> keys) |
Responsible for loading list of objects from the data source.
|
void init(java.util.Map<java.lang.String,java.lang.String> parameters, java.lang.String cacheId) throws java.lang.Exception
parameters
- Startup parameters defined in the configuration.cacheId
- Id of the cache.java.lang.Exception
ProviderCacheItem loadFromSource(java.lang.String key) throws java.lang.Exception
key
- Key used to reference object.java.lang.Exception
java.util.Map<java.lang.String,ProviderCacheItem> loadFromSource(java.util.Collection<java.lang.String> keys) throws java.lang.Exception
keys
- The collection of keys to be loaded from the data source.java.lang.Exception
ProviderDataStructureItem loadDataStructureFromSource(java.lang.String key, DistributedDataStructureType distributedDataStructureType) throws java.lang.Exception
key
- Key used to reference the object.distributedDataStructureType
- Type of collection.java.lang.Exception