Class CachingDefinedRegionsConfiguration
java.lang.Object
org.springframework.data.gemfire.config.annotation.support.AbstractAnnotationConfigSupport
org.springframework.data.gemfire.config.annotation.CachingDefinedRegionsConfiguration
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,org.springframework.beans.factory.BeanClassLoaderAware
,org.springframework.beans.factory.BeanFactoryAware
,org.springframework.context.annotation.ImportAware
,org.springframework.context.EnvironmentAware
@Configuration
public class CachingDefinedRegionsConfiguration
extends AbstractAnnotationConfigSupport
implements org.springframework.context.annotation.ImportAware
The
CachingDefinedRegionsConfiguration
class is a Spring @Configuration
class
that applies configuration to a Spring (Data GemFire/Geode) application to create GemFire/Geode cache
Regions
based on the use of Spring's Cache Abstraction to enable caching for application
service classes and methods.- Since:
- 2.0.0
- See Also:
-
Annotation
AnnotatedElement
GemFireCache
Region
RegionShortcut
ClientRegionShortcut
Pool
AnnotatedBeanDefinition
BeanDefinition
BeanPostProcessor
ConfigurableBeanFactory
AbstractBeanDefinition
BeanDefinitionBuilder
BeanDefinitionRegistry
BeanDefinitionRegistryPostProcessor
CacheConfig
CacheEvict
CachePut
Cacheable
Caching
Bean
Configuration
ImportAware
AnnotatedElementUtils
AnnotationUtils
EnableCachingDefinedRegions
AbstractAnnotationConfigSupport
BeanDefinitionRegistryPostProcessorSupport
CacheTypeAwareRegionFactoryBean
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
CachingDefinedRegionsConfiguration.AbstractCacheNameResolver
is an abstract base class encapsulating reusable functionality common to allCachingDefinedRegionsConfiguration.CacheNameResolver
implementations.static interface
CachingDefinedRegionsConfiguration.CacheNameResolver
is aFunctionalInterface
declaring a contract for all implementations used to resolve all cache names declared and used by a Spring application.protected static class
Nested classes/interfaces inherited from class org.springframework.data.gemfire.config.annotation.support.AbstractAnnotationConfigSupport
AbstractAnnotationConfigSupport.TypeResolver<T>
-
Field Summary
Fields inherited from class org.springframework.data.gemfire.config.annotation.support.AbstractAnnotationConfigSupport
CURRENT_THREAD_CONTEXT_CLASS_LOADER, INFRASTRUCTURE_ROLES, ORG_SPRINGFRAMEWORK_DATA_GEMFIRE_PACKAGE, ORG_SPRINGFRAMEWORK_PACKAGE, SPRING_DATA_GEMFIRE_PROPERTY_PREFIX
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.beans.factory.config.BeanPostProcessor
cachingAnnotationsRegionBeanRegistrar
(org.springframework.beans.factory.config.ConfigurableBeanFactory beanFactory) org.springframework.context.Lifecycle
protected Class<? extends Annotation>
Returns theAnnotation
type
that configures and createsRegions
for application serviceMethods
that are annotated with Spring's Cache Abstraction Annotations.Returns the configuredCachingDefinedRegionsConfiguration.CacheNameResolver
to resolve all the declared cache name on Spring application beans/components declared and registered in the Spring container (context).protected Optional<org.apache.geode.cache.client.ClientRegionShortcut>
Returns the configuredClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
.Returns the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server.protected Optional<org.apache.geode.cache.RegionShortcut>
Returns the configuredRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
.protected org.apache.geode.cache.client.ClientRegionShortcut
Resolves theClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
; defaults toClientRegionShortcut.PROXY
.protected String
Resolves the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server; defaults to DEFAULT.protected org.apache.geode.cache.RegionShortcut
Resolves theRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
; defaults toRegionShortcut.PARTITION
.void
setClientRegionShortcut
(org.apache.geode.cache.client.ClientRegionShortcut clientRegionShortcut) Configures theClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
.void
setImportMetadata
(org.springframework.core.type.AnnotationMetadata importMetadata) void
setPoolName
(String poolName) Configures the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server.void
setServerRegionShortcut
(org.apache.geode.cache.RegionShortcut serverRegionShortcut) Configures theRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
.Methods inherited from class org.springframework.data.gemfire.config.annotation.support.AbstractAnnotationConfigSupport
arrayOfPropertyNamesFor, arrayOfPropertyNamesFor, asArrayProperty, cacheClientProperty, cacheCompressionProperty, cacheOffHeapProperty, cachePeerProperty, cacheProperty, cacheServerProperty, clusterProperty, diskStoreProperty, entitiesProperty, gatewayReceiverProperty, gatewaySenderProperty, getAnnotationAttributes, getAnnotationAttributes, getAnnotationAttributes, getAnnotationTypeName, getAnnotationTypeSimpleName, getBeanClassLoader, getBeanFactory, getEnvironment, getEvaluationContext, getLogger, hasValue, hasValue, hasValue, httpServiceProperty, isAnnotationPresent, isAnnotationPresent, isNotInfrastructureBean, isNotInfrastructureBean, isNotInfrastructureClass, isNotInfrastructureRole, isUserLevelMethod, locatorProperty, logDebug, logDebug, logError, logError, loggingProperty, logInfo, logInfo, logWarning, logWarning, managementProperty, managerProperty, memcachedServiceProperty, namedCacheServerProperty, namedDiskStoreProperty, namedGatewaySenderProperty, namedPoolProperty, newEvaluationContext, newLogger, pdxProperty, poolProperty, propertyName, register, register, requireProperty, resolveAnnotation, resolveBeanClass, resolveBeanClass, resolveBeanClass, resolveBeanClassLoader, resolveBeanClassLoader, resolveBeanClassLoader, resolveBeanClassName, resolveProperty, resolveProperty, resolveProperty, resolveProperty, resolveProperty, resolveProperty, resolveProperty, resolveProperty, safeResolveType, securityProperty, serviceProperty, setBeanClassLoader, setBeanFactory, setEnvironment, sslProperty, statsProperty
-
Constructor Details
-
CachingDefinedRegionsConfiguration
public CachingDefinedRegionsConfiguration()
-
-
Method Details
-
getAnnotationType
Returns theAnnotation
type
that configures and createsRegions
for application serviceMethods
that are annotated with Spring's Cache Abstraction Annotations.- Specified by:
getAnnotationType
in classAbstractAnnotationConfigSupport
- Returns:
- the
Annotation
type
that configures and createsRegions
for application serviceMethods
that are annotated with Spring's Cache Abstraction Annotations. - See Also:
-
getCacheNameResolver
Returns the configuredCachingDefinedRegionsConfiguration.CacheNameResolver
to resolve all the declared cache name on Spring application beans/components declared and registered in the Spring container (context).- Returns:
- the configured
CachingDefinedRegionsConfiguration.CacheNameResolver
to resolve all teh caches used by the Spring application. - See Also:
-
setClientRegionShortcut
public void setClientRegionShortcut(org.apache.geode.cache.client.ClientRegionShortcut clientRegionShortcut) Configures theClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
.- Parameters:
clientRegionShortcut
-ClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
.- See Also:
-
ClientRegionShortcut
-
getClientRegionShortcut
Returns the configuredClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
.- Returns:
- an
Optional
ClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
. - See Also:
-
ClientRegionShortcut
setClientRegionShortcut(ClientRegionShortcut)
Optional
-
resolveClientRegionShortcut
protected org.apache.geode.cache.client.ClientRegionShortcut resolveClientRegionShortcut()Resolves theClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
; defaults toClientRegionShortcut.PROXY
.- Returns:
- the resolved
ClientRegionShortcut
specifying the data management policy to use when creating a clientRegion
; defaults toClientRegionShortcut.PROXY
. - See Also:
-
ClientRegionShortcut
getClientRegionShortcut()
-
setPoolName
Configures the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server.- Parameters:
poolName
-String
containing the name of the dedicatedPool
for all caching-defined clientRegions
.
-
getPoolName
Returns the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server. -
resolvePoolName
Resolves the name of the dedicatedPool
used by all caching-defined clientRegions
to send and receive data between the client and server; defaults to DEFAULT.- Returns:
- the
name
of the dedicatedPool
used by all caching-defined clientRegions
; defaults to DEFAULT. - See Also:
-
setServerRegionShortcut
public void setServerRegionShortcut(org.apache.geode.cache.RegionShortcut serverRegionShortcut) Configures theRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
.- Parameters:
serverRegionShortcut
-RegionShortcut
specifying the data management policy to use when creating a server (peer)Region
.- See Also:
-
RegionShortcut
-
getServerRegionShortcut
Returns the configuredRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
.- Returns:
- an
Optional
RegionShortcut
specifying the data management policy to use when creating a server (peer)Region
. - See Also:
-
setServerRegionShortcut(RegionShortcut)
RegionShortcut
Optional
-
resolveServerRegionShortcut
protected org.apache.geode.cache.RegionShortcut resolveServerRegionShortcut()Resolves theRegionShortcut
specifying the data management policy to use when creating a server (peer)Region
; defaults toRegionShortcut.PARTITION
.- Returns:
- the resolved
RegionShortcut
specifying the data management policy to use when creating a server (peer)Region
; defaults toRegionShortcut.PARTITION
. - See Also:
-
RegionShortcut
getServerRegionShortcut()
-
setImportMetadata
public void setImportMetadata(org.springframework.core.type.AnnotationMetadata importMetadata) - Specified by:
setImportMetadata
in interfaceorg.springframework.context.annotation.ImportAware
-
cachingAnnotationsRegionBeanRegistrar
@Bean public org.springframework.beans.factory.config.BeanPostProcessor cachingAnnotationsRegionBeanRegistrar(org.springframework.beans.factory.config.ConfigurableBeanFactory beanFactory) -
cachingDefinedRegionsCompositeLifecycleBean
@Bean public org.springframework.context.Lifecycle cachingDefinedRegionsCompositeLifecycleBean()
-