Spring Boot for VMware GemFire
Package org.springframework.geode.cache
Class AsyncInlineCachingRegionConfigurer<T,ID> 
java.lang.Object
org.springframework.geode.cache.AsyncInlineCachingRegionConfigurer<T,ID> 
- All Implemented Interfaces:
- org.springframework.core.Ordered,- org.springframework.data.gemfire.config.annotation.RegionConfigurer,- org.springframework.data.gemfire.config.annotation.support.Configurer<org.springframework.data.gemfire.client.ClientRegionFactoryBean<?,- ?>> 
public class AsyncInlineCachingRegionConfigurer<T,ID> 
extends Object
implements org.springframework.data.gemfire.config.annotation.RegionConfigurer
A Spring Data for Apache Geode 
RegionConfigurer implementation used to configure a target Region
 to use Asynchronous Inline Caching based on the Spring Data Repositories
 abstraction.- Since:
- 1.4.0
- See Also:
- 
- Function
- Predicate
- Cache
- Region
- AsyncEventListener
- AsyncEventQueue
- AsyncEventQueueFactory
- GatewayEventFilter
- GatewayEventSubstitutionFilter
- GatewaySender.OrderPolicy
- PeerRegionFactoryBean
- RegionConfigurer
- CrudRepository
- RepositoryAsyncEventListener.AsyncEventErrorHandler
 
- 
Field SummaryFieldsModifier and TypeFieldDescriptionFields inherited from interface org.springframework.core.OrderedHIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
- 
Constructor SummaryConstructorsConstructorDescriptionAsyncInlineCachingRegionConfigurer(org.springframework.data.repository.CrudRepository<T, ID> repository, Predicate<String> regionBeanName) Constructs a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the givenCrudRepositoryandPredicateidentifying theRegionon which Asynchronous Inline Caching will be configured.
- 
Method SummaryModifier and TypeMethodDescriptionapplyToListener(Function<org.apache.geode.cache.asyncqueue.AsyncEventListener, org.apache.geode.cache.asyncqueue.AsyncEventListener> asyncEventListenerPostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventListenerfor post processing.applyToQueue(Function<org.apache.geode.cache.asyncqueue.AsyncEventQueue, org.apache.geode.cache.asyncqueue.AsyncEventQueue> asyncEventQueuePostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventQueuefor post processing.applyToQueueFactory(Function<org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory, org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory> asyncEventQueueFactoryPostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventQueueFactoryfor post processing.voidConfigures the targetRegionbynamewith Asynchronous Inline Caching functionality.static <T,ID> AsyncInlineCachingRegionConfigurer<T, ID> Factory method used to construct a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the given Spring DataCrudRepositoryandStringidentifying the targetRegionon which to configure Asynchronous Inline Caching.static <T,ID> AsyncInlineCachingRegionConfigurer<T, ID> create(org.springframework.data.repository.CrudRepository<T, ID> repository, Predicate<String> regionBeanName) Factory method used to construct a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the given Spring DataCrudRepositoryandPredicateidentifying the targetRegionon which to configure Asynchronous Inline Caching.protected StringgenerateId(String regionBeanName) Generates a newIDfor theAsyncEventQueue.Gets thePredicateidentifying theRegionon which Asynchronous Inline Caching will be configured.Gets the Spring DataCrudRepositoryused to perform data access operations on an external data source triggered cache events and operations on the targetRegion.protected org.apache.geode.cache.asyncqueue.AsyncEventQueuenewAsyncEventQueue(org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory factory, String asyncEventQueueId, org.apache.geode.cache.asyncqueue.AsyncEventListener listener) Constructs (creates) a new instance ofAsyncEventQueueusing the givenAsyncEventQueueFactorywith the givenAEQ IDandAsyncEventListener.protected org.apache.geode.cache.asyncqueue.AsyncEventQueuenewAsyncEventQueue(org.apache.geode.cache.Cache peerCache, String regionBeanName) Constructs a new instance of anAsyncEventQueueto attach to the targetRegionconfigured for Asynchronous Inline Caching.protected org.apache.geode.cache.asyncqueue.AsyncEventQueueFactorynewAsyncEventQueueFactory(org.apache.geode.cache.Cache peerCache) Constructs (creates) a new instance of theAsyncEventQueueFactoryfrom the given peerCache.protected org.apache.geode.cache.asyncqueue.AsyncEventListenerConstructs a new Apache GeodeAsyncEventListenerto register on anAsyncEventQueueattached to the targetRegion, which uses theCrudRepositoryto perform data access operations on an external backend data source asynchronously when cache events and operations occur on the targetRegion.protected org.apache.geode.cache.asyncqueue.AsyncEventListenernewRepositoryAsyncEventListener(org.springframework.data.repository.CrudRepository<T, ID> repository) Constructs a new Apache GeodeAsyncEventListenerto register on anAsyncEventQueueattached to the targetRegion, which uses the givenCrudRepositoryto perform data access operations on an external, backend data source asynchronously when cache events and operations occur on the targetRegion.protected org.apache.geode.cache.asyncqueue.AsyncEventListenerpostProcess(org.apache.geode.cache.asyncqueue.AsyncEventListener asyncEventListener) Applies the user-definedFunctionto the framework constructed/providedAsyncEventListenerfor post processing.protected org.apache.geode.cache.asyncqueue.AsyncEventQueuepostProcess(org.apache.geode.cache.asyncqueue.AsyncEventQueue asyncEventQueue) Applies the user-definedFunctionto the framework constructed/providedAsyncEventQueuefor post-processing.protected org.apache.geode.cache.asyncqueue.AsyncEventQueueFactorypostProcess(org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory asyncEventQueueFactory) Applies the user-definedFunctionto the framework constructed/providedAsyncEventQueueFactoryfor post processing.Builder method used to configure aRepositoryAsyncEventListener.AsyncEventErrorHandlerto handle errors thrown while processingAsyncEventsin theAsyncEventListener.Builder method used to enable allAEQsattached toRegionshosted and distributed across the cache cluster to process cache events.Builder method used to enable theAsyncEventQueueto persist cache events to disk in order to preserve unprocessed cache events while offline.Builder method used to configure theAsyncEventQueueto conflate cache events in the queue.withQueueBatchSize(int batchSize) Builder method used to configure theAsyncEventQueuebatch size, which determines the number (i.e.withQueueBatchTimeInterval(Duration batchTimeInterval) Builder method used to configure theAsyncEventQueuebatch time intervaldetermining when the AEQ listener will be trigger before the number of cache events reaches any set size.withQueueDiskStore(String diskStoreName) Builder method used to configure thenameof theDiskStoreused by theAsyncEventQueueto persist or overflow cache events.Builder method used to configure theAsyncEventQueueto perform all disk write operations synchronously.withQueueDispatcherThreadCount(int dispatcherThreadCount) Builder method to configure the number ofThreadsto process the cache events (contents) in theAsyncEventQueuewhen the queue is parallel.Builder method used to configure whether theAsyncEventQueueis currently processing cache events or is paused.withQueueEventFilters(List<org.apache.geode.cache.wan.GatewayEventFilter> eventFilters) Builder method to configure theAsyncEventQueuewith aListofGatewayEventFiltersto filter cache events sent to the configured AEQ listener.withQueueEventSubstitutionFilter(org.apache.geode.cache.wan.GatewayEventSubstitutionFilter<ID, T> eventSubstitutionFilter) Builder method used to configure theAsyncEventQueuewith acache event substitution filterused to replace (or "substitute") the original cache entry event value enqueued in the AEQ.Builder method used to configure whether cacheRegionentry destroyed events due to expiration are forwarded to theAsyncEventQueue.withQueueMaxMemory(int maximumMemory) Builder method used to configure the maximum JVM Heap memory in megabytes used by theAsyncEventQueue.withQueueOrderPolicy(org.apache.geode.cache.wan.GatewaySender.OrderPolicy orderPolicy) Builder method used to configure theAsyncEventQueueorder of processing for cache events when the AEQ is serial and the AEQ is using multiple dispatcher threads.Builder method used to enable a singleAEQattached to aRegion(possibly) hosted and distributed across the cache cluster to process cache events.Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.data.gemfire.config.annotation.support.ConfigurergetOrderMethods inherited from interface org.springframework.data.gemfire.config.annotation.RegionConfigurerconfigure
- 
Field Details- 
DEFAULT_REGION_BEAN_NAME_PREDICATE
 
- 
- 
Constructor Details- 
AsyncInlineCachingRegionConfigurerpublic AsyncInlineCachingRegionConfigurer(@NonNull org.springframework.data.repository.CrudRepository<T, ID> repository, @Nullable Predicate<String> regionBeanName) Constructs a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the givenCrudRepositoryandPredicateidentifying theRegionon which Asynchronous Inline Caching will be configured.- Parameters:
- repository-- CrudRepositoryused to perform data access operations on an external data source triggered by cache events and operations on the identified- Region; must not be null.
- regionBeanName-- Predicateused to identify the- Regionby- nameon which Asynchronous Inline Caching will be configured.
- Throws:
- IllegalArgumentException- if- CrudRepositoryis null.
- See Also:
- 
- CrudRepository
- Predicate
 
 
 
- 
- 
Method Details- 
createpublic static <T,ID> AsyncInlineCachingRegionConfigurer<T,ID> create(@NonNull org.springframework.data.repository.CrudRepository<T, ID> repository, @Nullable Predicate<String> regionBeanName) Factory method used to construct a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the given Spring DataCrudRepositoryandPredicateidentifying the targetRegionon which to configure Asynchronous Inline Caching.- Type Parameters:
- T-- typeof the entity.
- ID-- typeof the identifier, or- Regionkey.
- Parameters:
- repository-- CrudRepositoryused to perform data access operations on an external data source triggered by cache events and operations on the identified- Region; must not be null.
- regionBeanName-- Predicateused to identify the- Regionby- nameon which Asynchronous Inline Caching will be configured.
- Returns:
- a new AsyncInlineCachingRegionConfigurer.
- Throws:
- IllegalArgumentException- if- CrudRepositoryis null.
- See Also:
 
- 
createpublic static <T,ID> AsyncInlineCachingRegionConfigurer<T,ID> create(@NonNull org.springframework.data.repository.CrudRepository<T, ID> repository, @Nullable String regionBeanName) Factory method used to construct a new instance ofAsyncInlineCachingRegionConfigurerinitialized with the given Spring DataCrudRepositoryandStringidentifying the targetRegionon which to configure Asynchronous Inline Caching.- Type Parameters:
- T-- typeof the entity.
- ID-- typeof the identifier, or- Regionkey.
- Parameters:
- repository-- CrudRepositoryused to perform data access operations on an external data source triggered by cache events and operations on the identified- Region; must not be null.
- regionBeanName-- Stringused to identify the- Regionby- nameon which Asynchronous Inline Caching will be configured.
- Returns:
- a new AsyncInlineCachingRegionConfigurer.
- Throws:
- IllegalArgumentException- if- CrudRepositoryis null.
- See Also:
- 
- CrudRepository
- create(CrudRepository, Predicate)
- String
 
 
- 
getRegionBeanNameGets thePredicateidentifying theRegionon which Asynchronous Inline Caching will be configured.
- 
getRepositoryGets the Spring DataCrudRepositoryused to perform data access operations on an external data source triggered cache events and operations on the targetRegion.- Returns:
- the Spring Data CrudRepositoryused to perform data access operations on an external data source triggered cache events and operations on the targetRegion; never null.
- See Also:
- 
- CrudRepository
 
 
- 
configurepublic void configure(String beanName, org.springframework.data.gemfire.PeerRegionFactoryBean<?, ?> bean) Configures the targetRegionbynamewith Asynchronous Inline Caching functionality. Effectively, this Configurer creates anAsyncEventQueueattached to the targetRegionwith a registeredRepositoryAsyncEventListenerto perform asynchronous data access operations triggered by cache operations to an external, backend data source using a Spring DataCrudRepository.- Specified by:
- configurein interface- org.springframework.data.gemfire.config.annotation.RegionConfigurer
- Parameters:
- beanName-- Stringspecifying the name of the target- Regionand bean name in the Spring container.
- bean-- PeerRegionFactoryBeancontaining the configuration of the target- Regionin the Spring container.
- See Also:
- 
- PeerRegionFactoryBean
- newAsyncEventQueue(Cache, String)
 
 
- 
generateIdGenerates a newIDfor theAsyncEventQueue.
- 
newAsyncEventQueueprotected org.apache.geode.cache.asyncqueue.AsyncEventQueue newAsyncEventQueue(@NonNull org.apache.geode.cache.Cache peerCache, @NonNull String regionBeanName) Constructs a new instance of anAsyncEventQueueto attach to the targetRegionconfigured for Asynchronous Inline Caching.- Parameters:
- peerCache- reference to the- peer cache; must not be null.
- regionBeanName-- nameof the target- Region; must not be null.
- Returns:
- a new AsyncEventQueue.
- See Also:
 
- 
newAsyncEventQueue@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventQueue newAsyncEventQueue(@NonNull org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory factory, @NonNull String asyncEventQueueId, @NonNull org.apache.geode.cache.asyncqueue.AsyncEventListener listener) Constructs (creates) a new instance ofAsyncEventQueueusing the givenAsyncEventQueueFactorywith the givenAEQ IDandAsyncEventListener.- Parameters:
- factory-- AsyncEventQueueFactoryused to create the- AsyncEventQueue; must not be null.
- asyncEventQueueId-- Stringcontaining the ID for the- AsyncEventQueue; must not be null.
- listener-- AsyncEventListenerregistered with the- AsyncEventQueueto process cache events from the- AsyncEventQueueattached to the- Region.
- Returns:
- a new AsyncEventQueuewith theIDand registeredAsyncEventListener.
- See Also:
- 
- AsyncEventQueueFactory
- AsyncEventQueue
- AsyncEventListener
 
 
- 
newAsyncEventQueueFactory@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory newAsyncEventQueueFactory(@NonNull org.apache.geode.cache.Cache peerCache) Constructs (creates) a new instance of theAsyncEventQueueFactoryfrom the given peerCache.- Parameters:
- peerCache- Peer- Cacheinstance used to create an instance of the- AsyncEventQueueFactory; must not be null.
- Returns:
- a new instance of AsyncEventQueueFactoryto create aAsyncEventQueue.
- See Also:
- 
- AsyncEventQueueFactory
- Cache
 
 
- 
newRepositoryAsyncEventListener@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventListener newRepositoryAsyncEventListener()Constructs a new Apache GeodeAsyncEventListenerto register on anAsyncEventQueueattached to the targetRegion, which uses theCrudRepositoryto perform data access operations on an external backend data source asynchronously when cache events and operations occur on the targetRegion.- Returns:
- a new RepositoryAsyncEventListener.
- See Also:
 
- 
newRepositoryAsyncEventListener@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventListener newRepositoryAsyncEventListener(@NonNull org.springframework.data.repository.CrudRepository<T, ID> repository) Constructs a new Apache GeodeAsyncEventListenerto register on anAsyncEventQueueattached to the targetRegion, which uses the givenCrudRepositoryto perform data access operations on an external, backend data source asynchronously when cache events and operations occur on the targetRegion.- Parameters:
- repository- Spring Data- CrudRepositoryused to perform data access operations on the external, backend data source; must not be null.
- Returns:
- a new RepositoryAsyncEventListener.
- See Also:
- 
- RepositoryAsyncEventListener
- AsyncEventListener
- getRepository()
 
 
- 
postProcess@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventListener postProcess(@NonNull org.apache.geode.cache.asyncqueue.AsyncEventListener asyncEventListener) Applies the user-definedFunctionto the framework constructed/providedAsyncEventListenerfor post processing.- Parameters:
- asyncEventListener-- AsyncEventListenerconstructed by the framework and post processed by end-user code encapsulated in the- configured- Function.
- Returns:
- the post-processed AsyncEventListener.
- See Also:
- 
- AsyncEventListener
- applyToListener(Function)
 
 
- 
postProcess@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventQueue postProcess(@NonNull org.apache.geode.cache.asyncqueue.AsyncEventQueue asyncEventQueue) Applies the user-definedFunctionto the framework constructed/providedAsyncEventQueuefor post-processing.- Parameters:
- asyncEventQueue-- AsyncEventQueueconstructed by the framework and post processed by end-user code encapsulated in the- configured- Function.
- Returns:
- the post-processed AsyncEventQueue.
- See Also:
- 
- AsyncEventQueue
- applyToQueue(Function)
 
 
- 
postProcess@NonNull protected org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory postProcess(@NonNull org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory asyncEventQueueFactory) Applies the user-definedFunctionto the framework constructed/providedAsyncEventQueueFactoryfor post processing.- Parameters:
- asyncEventQueueFactory-- AsyncEventQueueFactoryconstructed by the framework and post processed by end-user code encapsulated in the- configured- Function.
- Returns:
- the post-processed AsyncEventQueueFactory.
- See Also:
- 
- AsyncEventQueueFactory
- applyToQueueFactory(Function)
 
 
- 
applyToListenerpublic AsyncInlineCachingRegionConfigurer<T,ID> applyToListener(@Nullable Function<org.apache.geode.cache.asyncqueue.AsyncEventListener, org.apache.geode.cache.asyncqueue.AsyncEventListener> asyncEventListenerPostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventListenerfor post processing.- Parameters:
- asyncEventListenerPostProcessor- user-defined- Functionencapsulating the logic applied to the framework constructed/provided- AsyncEventListenerfor post-processing.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- AsyncEventListener
- Function
 
 
- 
applyToQueuepublic AsyncInlineCachingRegionConfigurer<T,ID> applyToQueue(@Nullable Function<org.apache.geode.cache.asyncqueue.AsyncEventQueue, org.apache.geode.cache.asyncqueue.AsyncEventQueue> asyncEventQueuePostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventQueuefor post processing.- Parameters:
- asyncEventQueuePostProcessor- user-defined- Functionencapsulating the logic applied to the framework constructed- AsyncEventQueuefor post-processing.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- AsyncEventQueue
- Function
 
 
- 
applyToQueueFactorypublic AsyncInlineCachingRegionConfigurer<T,ID> applyToQueueFactory(@Nullable Function<org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory, org.apache.geode.cache.asyncqueue.AsyncEventQueueFactory> asyncEventQueueFactoryPostProcessor) Builder method used to configure the given user-definedFunctionapplied to the framework constructed and providedAsyncEventQueueFactoryfor post processing.- Parameters:
- asyncEventQueueFactoryPostProcessor- user-defined- Functionencapsulating the logic applied to the framework constructed- AsyncEventQueueFactoryfor post-processing.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- AsyncEventQueueFactory
- Function
 
 
- 
withAsyncEventErrorHandlerpublic AsyncInlineCachingRegionConfigurer<T,ID> withAsyncEventErrorHandler(@Nullable RepositoryAsyncEventListener.AsyncEventErrorHandler errorHandler) Builder method used to configure aRepositoryAsyncEventListener.AsyncEventErrorHandlerto handle errors thrown while processingAsyncEventsin theAsyncEventListener.- Parameters:
- errorHandler-- RepositoryAsyncEventListener.AsyncEventErrorHandlerused to handle errors thrown while processing- AsyncEventsin the- AsyncEventListener.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
 
- 
withParallelQueueBuilder method used to enable allAEQsattached toRegionshosted and distributed across the cache cluster to process cache events. Default is false, or serial.- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
 
- 
withPersistentQueueBuilder method used to enable theAsyncEventQueueto persist cache events to disk in order to preserve unprocessed cache events while offline. Keep in mind that theAsyncEventQueuemust be persistent if the dataRegionto which the AEQ is attached is persistent. Default is false.- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueBatchConflationEnabledBuilder method used to configure theAsyncEventQueueto conflate cache events in the queue. When conflation is enabled, the AEQ listener will only receive the latest update in the AEQ for cache entry based on key. Defaults to false.- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueBatchSizeBuilder method used to configure theAsyncEventQueuebatch size, which determines the number (i.e. threshold) of cache events that will trigger the AEQ listener, before any set period of time. The batch size is often used in tandem with the batch time interval, which determines when the AEQ listener will be invoked after a period of time if the batch size is not reached within the period so that cache events can also be processed in a timely manner if they are occurring infrequently. Defaults to 100.- Parameters:
- batchSize- the- numberof cache events in the queue before the AEQ listener is called.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
 
- 
withQueueBatchTimeIntervalpublic AsyncInlineCachingRegionConfigurer<T,ID> withQueueBatchTimeInterval(Duration batchTimeInterval) Builder method used to configure theAsyncEventQueuebatch time intervaldetermining when the AEQ listener will be trigger before the number of cache events reaches any set size. TheDurationis converted to milliseconds (ms), as expected by the configuration of theAsyncEventQueue. The batch time interval is often used in tandem with batch size, which determines for how many cache events in the queue will trigger the AEQ listener. If cache events are occurring rather frequently, then the batch size can help reduce memory consumption by processing the cache events before the batch time interval expires. Defaults to 5 ms.- Parameters:
- batchTimeInterval-- Durationof time to determine when the AEQ listener should be invoked with any existing cache events in the queue.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueDiskStoreBuilder method used to configure thenameof theDiskStoreused by theAsyncEventQueueto persist or overflow cache events. By default, the AEQ will write cache events to the DEFAULTDiskStore.- Parameters:
- diskStoreName-- nameof the- DiskStore.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueDiskSynchronizationEnabledBuilder method used to configure theAsyncEventQueueto perform all disk write operations synchronously. Default is true.- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueDispatcherThreadCountpublic AsyncInlineCachingRegionConfigurer<T,ID> withQueueDispatcherThreadCount(int dispatcherThreadCount) Builder method to configure the number ofThreadsto process the cache events (contents) in theAsyncEventQueuewhen the queue is parallel. When a queue is parallel, the total number of queues is determined by the number of Geode members hosting theRegionto which the queue is attached. When a queue is serial and multiple dispatcher threads are configured, Geode creates an additional copy of the queue for each thread on each Geode member that hosts the queue. When the queue is serial and multiple dispatcher threads are configure, then you can use theGatewaySenderGatewaySender.OrderPolicyto control the distribution of cache events from the queue by the threads. Default is 5.- Parameters:
- dispatcherThreadCount-- numberof dispatcher- Threadsprocessing cache events in the queue.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueEventDispatchingPausedBuilder method used to configure whether theAsyncEventQueueis currently processing cache events or is paused. When paused, cache events will not be dispatched to the AEQ listener for processing. Call theAsyncEventQueue.resumeEventDispatching()to resume cache event processing and AEQ listener callbacks.- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueEventFilterspublic AsyncInlineCachingRegionConfigurer<T,ID> withQueueEventFilters(List<org.apache.geode.cache.wan.GatewayEventFilter> eventFilters) Builder method to configure theAsyncEventQueuewith aListofGatewayEventFiltersto filter cache events sent to the configured AEQ listener.- Parameters:
- eventFilters-- Listof- GatewayEventFiltersused to control and filter the cache events sent to the configured AEQ listener.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- GatewayEventFilter
- List
 
 
- 
withQueueEventSubstitutionFilterpublic AsyncInlineCachingRegionConfigurer<T,ID> withQueueEventSubstitutionFilter(@Nullable org.apache.geode.cache.wan.GatewayEventSubstitutionFilter<ID, T> eventSubstitutionFilter) Builder method used to configure theAsyncEventQueuewith acache event substitution filterused to replace (or "substitute") the original cache entry event value enqueued in the AEQ.- Parameters:
- eventSubstitutionFilter-- GatewayEventSubstitutionFilterused to replace/substitute the value in the enqueued cache entry event.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- GatewayEventSubstitutionFilter
 
 
- 
withQueueForwardedExpirationDestroyEventsBuilder method used to configure whether cacheRegionentry destroyed events due to expiration are forwarded to theAsyncEventQueue.- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueMaxMemoryBuilder method used to configure the maximum JVM Heap memory in megabytes used by theAsyncEventQueue. After the maximum memory threshold is reached then the AEQ overflows cache events to disk. Default to 100 MB.- Parameters:
- maximumMemory-- Integervalue specifying the maximum amount of memory in megabytes used by the AEQ to capture cache events.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
 
- 
withQueueOrderPolicypublic AsyncInlineCachingRegionConfigurer<T,ID> withQueueOrderPolicy(@Nullable org.apache.geode.cache.wan.GatewaySender.OrderPolicy orderPolicy) Builder method used to configure theAsyncEventQueueorder of processing for cache events when the AEQ is serial and the AEQ is using multiple dispatcher threads.- Parameters:
- orderPolicy-- GatewaySender- GatewaySender.OrderPolicyused to determine the order of processing for cache events when the AEQ is serial and uses multiple dispatcher threads.
- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
- 
- GatewaySender.OrderPolicy
 
 
- 
withSerialQueueBuilder method used to enable a singleAEQattached to aRegion(possibly) hosted and distributed across the cache cluster to process cache events. Default is false, or serial.- Returns:
- this AsyncInlineCachingRegionConfigurer.
- See Also:
 
 
- 
