Class BackingMapScheme
- All Implemented Interfaces:
BackingMapManagerBuilder,BuilderCustomization,MapBuilder,NamedCacheBuilder,ServiceBuilder,CachingScheme,ObservableCachingScheme,Scheme,ServiceScheme
The
BackingMapScheme class is responsible for building a fully
configured instance of a backing map.- Since:
- Coherence 12.1.2
- Author:
- pfm 2011.11.30
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.tangosol.coherence.config.builder.MapBuilder
MapBuilder.Dependencies -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intA custom backup storage.static final intA file mapped backup storage.static final intA Flash Journal backup storage.static final intAn off-heap backup storage.static final intAn on-heap backup storage.static final intA Ram Journal backup storage.static final intA referenced scheme provides backup storage.Fields inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
m_serviceDependenciesFields inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
DELIM_APPLICATION_SCOPE, DELIM_DOMAIN_PARTITION -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidetReadLocatorBuilder(ReadLocatorBuilder bldrReadLocator) Sets thebuilderthat is capable of building BiFunction's that return the Member reads for a partitioned cache should be targeted against.Return the inner scheme.Return a builder that is capable of building BiFunction's that return the Member reads for a partitioned cache should be targeted against.Obtains theExpressiondefining the name of theStorageAccessAuthorizer.isFederateApplySynthetic(ParameterResolver resolver) Return true iff received federated changes should be applied locally as synthetic updates.booleanisPartitioned(ParameterResolver resolver, boolean fDefault) Return true if the partitioned flag is set explicitly or a journal map is used.isSlidingExpiry(ParameterResolver resolver) Return true iff sliding expiry is enabled.booleanisTransient(ParameterResolver resolver) Return true if the backing map is transient.realizeMap(ParameterResolver resolver, MapBuilder.Dependencies dependencies) Realize aMapbased on the state of theMapBuilder, resolvable parameters and providedMapBuilder.Dependencies.voidSet whether incoming federated changes should be applied locally as synthetic updates.voidsetInnerScheme(CachingScheme scheme) Set the inner scheme.voidsetPartitioned(Expression<String> expr) Set the partitioned string.voidsetSlidingExpiry(Expression<Boolean> expr) Set the SlidingExpiry flag.voidsetStorageAccessAuthorizer(Expression<String> exprStorageAccessAuthorizer) Sets theExpressiondefining the name of theStorageAccessAuthorizer.voidsetTransient(Expression<Boolean> expr) Set the transient flag.protected voidvalidate(ParameterResolver resolver) Validate the properties.Methods inherited from class com.tangosol.coherence.config.scheme.AbstractLocalCachingScheme
getCustomBuilder, getEventInterceptorBuilders, getServiceType, isRunningClusterNeeded, setCustomBuilderMethods inherited from class com.tangosol.coherence.config.scheme.AbstractCachingScheme
establishMapListeners, getDefaultParameterResolver, getListenerBuilder, realizeBackingMapManager, realizeCache, setListenerBuilderMethods inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
ensureService, getDefaultServiceName, getScopedServiceName, getScopeName, getServiceBuilder, getServiceDependencies, getServiceName, getXml, injectScopeNameIntoService, isAutoStart, realizeService, setAutoStart, setScopeName, setServiceDependencies, setServiceName, setXmlMethods inherited from class com.tangosol.coherence.config.scheme.AbstractScheme
getSchemeName, isAnonymous, setSchemeName, validateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.tangosol.coherence.config.scheme.Scheme
getSchemeName, isAnonymousMethods inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
getScopedServiceName, getServiceBuilder, getServiceName, isAutoStart
-
Field Details
-
ON_HEAP
public static final int ON_HEAPAn on-heap backup storage.- See Also:
-
OFF_HEAP
public static final int OFF_HEAPAn off-heap backup storage.- See Also:
-
FILE_MAPPED
public static final int FILE_MAPPEDA file mapped backup storage.- See Also:
-
CUSTOM
public static final int CUSTOMA custom backup storage.- See Also:
-
SCHEME
public static final int SCHEMEA referenced scheme provides backup storage.- See Also:
-
FLASHJOURNAL
public static final int FLASHJOURNALA Flash Journal backup storage.- See Also:
-
RAMJOURNAL
public static final int RAMJOURNALA Ram Journal backup storage.- See Also:
-
-
Constructor Details
-
BackingMapScheme
public BackingMapScheme()
-
-
Method Details
-
realizeMap
Realize aMapbased on the state of theMapBuilder, resolvable parameters and providedMapBuilder.Dependencies.- Specified by:
realizeMapin interfaceMapBuilder- Overrides:
realizeMapin classAbstractCachingScheme- Parameters:
resolver- theParameterResolverdependencies- theMapBuilder.Dependenciesfor realizing theMap- Returns:
- a
Map
-
getInnerScheme
Return the inner scheme.- Returns:
- the inner scheme
-
setInnerScheme
Set the inner scheme.- Parameters:
scheme- the inner scheme
-
setPartitioned
Set the partitioned string.- Parameters:
expr- the Boolean expression set to 'true' or 'observable' if the backing map is partitioned
-
isPartitioned
Return true if the partitioned flag is set explicitly or a journal map is used.- Parameters:
resolver- the ParameterResolverfDefault- the default partitioned flag- Returns:
- true if the map is partitioned
-
isTransient
Return true if the backing map is transient.- Parameters:
resolver- the ParameterResolver- Returns:
- true if the backing map is transient
-
setTransient
Set the transient flag.- Parameters:
expr- true to make the backing map transient.
-
isSlidingExpiry
Return true iff sliding expiry is enabled.- Parameters:
resolver- the ParameterResolver- Returns:
- true iff sliding expiry is enabled
-
setSlidingExpiry
Set the SlidingExpiry flag.- Parameters:
expr- true to enable sliding expiry for the backing map
-
isFederateApplySynthetic
Return true iff received federated changes should be applied locally as synthetic updates.- Parameters:
resolver- the ParameterResolver- Returns:
- true iff received federated changes should be applied locally as synthetic updates
- Since:
- 12.2.1.4
-
setFederateApplySynthetic
@Injectable("federate-apply-synthetic") public void setFederateApplySynthetic(Expression<Boolean> expr) Set whether incoming federated changes should be applied locally as synthetic updates.- Parameters:
expr- true to apply incoming federated changes as synthetic- Since:
- 12.2.1.4
-
getStorageAccessAuthorizer
Obtains theExpressiondefining the name of theStorageAccessAuthorizer.- Returns:
- the name of the
StorageAccessAuthorizerornullif one has not been configured.
-
setStorageAccessAuthorizer
@Injectable("storage-authorizer") public void setStorageAccessAuthorizer(Expression<String> exprStorageAccessAuthorizer) Sets theExpressiondefining the name of theStorageAccessAuthorizer.- Parameters:
exprStorageAccessAuthorizer- theExpression
-
getReadLocatorBuilder
Return a builder that is capable of building BiFunction's that return the Member reads for a partitioned cache should be targeted against.- Returns:
- a builder that is capable of building BiFunction's that return the Member reads for a partitioned cache should be targeted against
-
etReadLocatorBuilder
Sets thebuilderthat is capable of building BiFunction's that return the Member reads for a partitioned cache should be targeted against.- Parameters:
bldrReadLocator- thebuilder
-
validate
Validate the properties.- Overrides:
validatein classAbstractCachingScheme- Parameters:
resolver- the ParameterResolver needed to resolve expressions
-