public class GemFireCacheProvider
extends java.lang.Object
implements org.hibernate.cache.CacheProvider
Constructor and Description |
---|
GemFireCacheProvider() |
Modifier and Type | Method and Description |
---|---|
org.hibernate.cache.Cache |
buildCache(java.lang.String regionName,
java.util.Properties properties)
Configure the cache
|
static org.apache.logging.log4j.Logger |
getLogger() |
boolean |
isMinimalPutsEnabledByDefault() |
long |
nextTimestamp()
Generate a timestamp
|
protected Region |
retrieveOrCreateRegion(java.lang.String regionName)
Returns the region if already created, otherwise first tries to create it
from cache.xml, if not specified in cache.xml, create the region from the
properties specified in hibernate.cfg.xml.
|
void |
start(java.util.Properties properties)
Callback to perform any necessary initialization of the underlying cache
implementation during SessionFactory construction.
|
void |
stop()
Callback to perform any necessary cleanup of the underlying cache
implementation during SessionFactory.close().
|
protected Cache _cache
public org.hibernate.cache.Cache buildCache(java.lang.String regionName, java.util.Properties properties) throws org.hibernate.cache.CacheException
buildCache
in interface org.hibernate.cache.CacheProvider
regionName
- the name of the cache regionproperties
- configuration settingsorg.hibernate.cache.CacheException
public boolean isMinimalPutsEnabledByDefault()
isMinimalPutsEnabledByDefault
in interface org.hibernate.cache.CacheProvider
public long nextTimestamp()
nextTimestamp
in interface org.hibernate.cache.CacheProvider
protected Region retrieveOrCreateRegion(java.lang.String regionName)
regionName
- public void start(java.util.Properties properties) throws org.hibernate.cache.CacheException
start
in interface org.hibernate.cache.CacheProvider
properties
- current configuration settings.org.hibernate.cache.CacheException
public void stop()
stop
in interface org.hibernate.cache.CacheProvider
public static org.apache.logging.log4j.Logger getLogger()