Class FederatedScheme
- java.lang.Object
-
- com.tangosol.coherence.config.scheme.AbstractScheme
-
- com.tangosol.coherence.config.scheme.AbstractServiceScheme<D>
-
- com.tangosol.coherence.config.scheme.AbstractCachingScheme<com.tangosol.internal.net.service.grid.PartitionedCacheDependencies>
-
- com.tangosol.coherence.config.scheme.DistributedScheme
-
- com.tangosol.coherence.config.scheme.FederatedScheme
-
- All Implemented Interfaces:
BackingMapManagerBuilder,MapBuilder,NamedCacheBuilder,ServiceBuilder,BundlingScheme,CachingScheme,ClusteredCachingScheme,ObservableCachingScheme,Scheme,ServiceScheme
public class FederatedScheme extends DistributedScheme
A FederatedScheme creates the infrastructure required for federated caches.- Since:
- 12.2.1
- Author:
- pp 2012.02.28
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFederatedScheme.NameConverterThe NameConverter is an implementation ofConverterthat converts an internal cache name to a cache-mapping, binding it to a federated scheme.static classFederatedScheme.TopologyReferenceThe TopologyReference class is used to reference a Federation defined in the operational config.-
Nested classes/interfaces inherited from class com.tangosol.coherence.config.scheme.DistributedScheme
DistributedScheme.BackupConfig
-
Nested classes/interfaces inherited from interface com.tangosol.coherence.config.builder.MapBuilder
MapBuilder.Dependencies
-
-
Field Summary
Fields Modifier and Type Field Description static StringJOURNALCACHE_HIGHUNITSThe name of the XML element to set the high-units on the cache for federation journal entries.-
Fields inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
m_serviceDependencies
-
Fields inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
DELIM_APPLICATION_SCOPE, DELIM_DOMAIN_PARTITION
-
-
Constructor Summary
Constructors Constructor Description FederatedScheme()Construct aFederatedScheme.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description StringgetAckCacheName()Return the name of the ack cache for this service.AddressProvidergetAddressProvider()Return the configured address-provider builder.StringgetEnvelopeCacheName()Return the name of the envelope cache for this service.Set<String>getInternalCacheNames()Return a set of internal cache names.BackingMapSchemegetJournalcacheBackingMapScheme()Return theBackingMapSchemewhich builds the backing map for federation's internal caches.StringgetJournalCacheName()Return the name of the journal cache for this service.FederatedServiceLoadBalancerBuildergetLoadBalancerBuilder()Return the load-balancer builder.FederatedScheme.NameConvertergetNameConverter()Return a converter that converts an internal cache name to a cache-mapping that ties it to this federated scheme.StringgetParticipantDestination()Return the Participant destination name.StringgetServiceType()Return the service type.SocketProviderBuildergetSocketProviderBuilder()Return the configured socket provider builderList<FederatedScheme.TopologyReference>getTopologies()Return the list of topology references.Set<String>initInternalCacheNames()Initialize the internal cache names.BackingMapManagerrealizeBackingMapManager(ConfigurableCacheFactory factory)Realize aBackingMapManagerto be scoped by the specifiedConfigurableCacheFactory.voidsetAddressProvider(ParameterizedBuilder<AddressProvider> addrProviderBuilder)Set the address provider.voidsetFederatedLoading(boolean fFederatedLoading)Set the flag to indicate if the cache store load should be federated.voidsetJournalcacheBackingMapScheme(BackingMapScheme scheme)Set theBackingMapSchemewhich builds the backing map for federation's internal caches.voidsetJournalcacheHighunits(int nHighUnits)Deprecated.voidsetJournalcacheHighunits(String sHighUnits)Set the high-units limit for the federation journal cache.voidsetLoadBalancer(FederatedServiceLoadBalancerBuilder bldrLoadBalancer)Set the load-balancer builder.voidsetParticipantDestination(String sParticipantDest)Set the Participant destination name.voidsetSendOldValue(boolean fSendOldValue)Set the flag to indicate if the old value should be sent when replicating.voidsetSocketProviderBuilder(SocketProviderBuilder builder)Set theSocketProviderBuilder.voidsetTopologies(List<FederatedScheme.TopologyReference> listRefs)Set the list of topology references.protected voidvalidate()Validate the properties.-
Methods inherited from class com.tangosol.coherence.config.scheme.DistributedScheme
getBackingMapScheme, getBackupMapConfig, getBundleManager, getEventInterceptorBuilders, isRunningClusterNeeded, setBackingMapScheme, setBackupMapConfig, setBundleManager, setEventInterceptorBuilders
-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractCachingScheme
establishMapListeners, getDefaultParameterResolver, getListenerBuilder, realizeCache, realizeMap, setListenerBuilder, validate
-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractServiceScheme
ensureService, getDefaultServiceName, getScopedServiceName, getScopeName, getServiceBuilder, getServiceDependencies, getServiceName, getXml, injectScopeNameIntoService, isAutoStart, realizeService, setApplicationContext, setAutoStart, setScopeName, setServiceDependencies, setServiceName, setXml
-
Methods inherited from class com.tangosol.coherence.config.scheme.AbstractScheme
getSchemeName, isAnonymous, setSchemeName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.tangosol.coherence.config.scheme.Scheme
getSchemeName, isAnonymous
-
Methods inherited from interface com.tangosol.coherence.config.scheme.ServiceScheme
getScopedServiceName, getServiceBuilder, getServiceName, isAutoStart
-
-
-
-
Field Detail
-
JOURNALCACHE_HIGHUNITS
public static final String JOURNALCACHE_HIGHUNITS
The name of the XML element to set the high-units on the cache for federation journal entries.- Since:
- 12.2.1.4
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
FederatedScheme
public FederatedScheme()
Construct aFederatedScheme.
-
-
Method Detail
-
getServiceType
public String getServiceType()
Return the service type.- Specified by:
getServiceTypein interfaceServiceScheme- Overrides:
getServiceTypein classDistributedScheme- Returns:
- the service type
-
realizeBackingMapManager
public BackingMapManager realizeBackingMapManager(ConfigurableCacheFactory factory)
Description copied from class:AbstractCachingSchemeRealize aBackingMapManagerto be scoped by the specifiedConfigurableCacheFactory.- Specified by:
realizeBackingMapManagerin interfaceBackingMapManagerBuilder- Overrides:
realizeBackingMapManagerin classAbstractCachingScheme<com.tangosol.internal.net.service.grid.PartitionedCacheDependencies>- Parameters:
factory- theConfigurableCacheFactory- Returns:
- a
BackingMapManager
-
validate
protected void validate()
Validate the properties.- Overrides:
validatein classAbstractScheme
-
getLoadBalancerBuilder
public FederatedServiceLoadBalancerBuilder getLoadBalancerBuilder()
Return the load-balancer builder.- Returns:
- the load balancer builder
-
setLoadBalancer
@Injectable("load-balancer") public void setLoadBalancer(FederatedServiceLoadBalancerBuilder bldrLoadBalancer)
Set the load-balancer builder.- Parameters:
bldrLoadBalancer- the federation service load-balancer
-
getParticipantDestination
public String getParticipantDestination()
Return the Participant destination name.The service name will be returned if no destination name has been specified.
- Returns:
- the Participant destination name
- Since:
- 14.1.2.0.0
-
setParticipantDestination
@Injectable("participant-destination-name") public void setParticipantDestination(String sParticipantDest)
Set the Participant destination name.- Parameters:
sParticipantDest- the destination name- Since:
- 14.1.2.0.0
-
getTopologies
public List<FederatedScheme.TopologyReference> getTopologies()
Return the list of topology references.- Returns:
- the list of topology references
-
setTopologies
@Injectable public void setTopologies(List<FederatedScheme.TopologyReference> listRefs)
Set the list of topology references.- Parameters:
listRefs- the list of topology references
-
setJournalcacheHighunits
@Injectable public void setJournalcacheHighunits(String sHighUnits)
Set the high-units limit for the federation journal cache.- Parameters:
sHighUnits- the high-units limit.- Since:
- 12.2.1.4
-
setJournalcacheHighunits
@Deprecated public void setJournalcacheHighunits(int nHighUnits)
Deprecated.Set the high-units limit for the federation journal cache.- Parameters:
nHighUnits- the high-units limit.
-
getJournalcacheBackingMapScheme
public BackingMapScheme getJournalcacheBackingMapScheme()
Return theBackingMapSchemewhich builds the backing map for federation's internal caches.- Returns:
- the scheme
- Since:
- 12.2.1.4
-
setJournalcacheBackingMapScheme
@Injectable public void setJournalcacheBackingMapScheme(BackingMapScheme scheme)
Set theBackingMapSchemewhich builds the backing map for federation's internal caches.- Parameters:
scheme- the scheme builder- Since:
- 12.2.1.4
-
setSendOldValue
@Injectable public void setSendOldValue(boolean fSendOldValue)
Set the flag to indicate if the old value should be sent when replicating.- Parameters:
fSendOldValue- true if the old value should be sent.
-
setFederatedLoading
@Injectable("backing-map-scheme/read-write-backing-map-scheme/cachestore-scheme/federated-loading") public void setFederatedLoading(boolean fFederatedLoading)
Set the flag to indicate if the cache store load should be federated.- Parameters:
fFederatedLoading- true if the cache store load should be federated.
-
getAddressProvider
public AddressProvider getAddressProvider()
Return the configured address-provider builder.- Returns:
- the configured address provider builder or null
-
setAddressProvider
@Injectable("address-provider") public void setAddressProvider(ParameterizedBuilder<AddressProvider> addrProviderBuilder)
Set the address provider.- Parameters:
addrProviderBuilder- the federation service address provider builder
-
getSocketProviderBuilder
public SocketProviderBuilder getSocketProviderBuilder()
Return the configured socket provider builder- Returns:
- the configured socket provider builder
-
setSocketProviderBuilder
@Injectable("socket-provider") public void setSocketProviderBuilder(SocketProviderBuilder builder)
Set theSocketProviderBuilder.- Parameters:
builder- the configured socket provider builder
-
getAckCacheName
public String getAckCacheName()
Return the name of the ack cache for this service.- Returns:
- the ack cache name
-
getEnvelopeCacheName
public String getEnvelopeCacheName()
Return the name of the envelope cache for this service.- Returns:
- the envelope cache name
-
getJournalCacheName
public String getJournalCacheName()
Return the name of the journal cache for this service.- Returns:
- the journal cache name
-
getInternalCacheNames
public Set<String> getInternalCacheNames()
Return a set of internal cache names.- Returns:
- set of internal cache names
-
initInternalCacheNames
public Set<String> initInternalCacheNames()
Initialize the internal cache names.Needs to be called prior to using the getters on the internal cache names and set of cache names.
- Returns:
- the set of internal cache names
-
getNameConverter
public FederatedScheme.NameConverter getNameConverter()
Return a converter that converts an internal cache name to a cache-mapping that ties it to this federated scheme.- Returns:
- internal cache name converter
-
-