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 class
FederatedScheme.NameConverter
The NameConverter is an implementation ofConverter
that converts an internal cache name to a cache-mapping, binding it to a federated scheme.static class
FederatedScheme.TopologyReference
The 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 String
JOURNALCACHE_HIGHUNITS
The 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 String
getAckCacheName()
Return the name of the ack cache for this service.AddressProvider
getAddressProvider()
Return the configured address-provider builder.String
getEnvelopeCacheName()
Return the name of the envelope cache for this service.Set<String>
getInternalCacheNames()
Return a set of internal cache names.BackingMapScheme
getJournalcacheBackingMapScheme()
Return theBackingMapScheme
which builds the backing map for federation's internal caches.String
getJournalCacheName()
Return the name of the journal cache for this service.FederatedServiceLoadBalancerBuilder
getLoadBalancerBuilder()
Return the load-balancer builder.FederatedScheme.NameConverter
getNameConverter()
Return a converter that converts an internal cache name to a cache-mapping that ties it to this federated scheme.String
getParticipantDestination()
Return the Participant destination name.String
getServiceType()
Return the service type.SocketProviderBuilder
getSocketProviderBuilder()
Return the configured socket provider builderList<FederatedScheme.TopologyReference>
getTopologies()
Return the list of topology references.Set<String>
initInternalCacheNames()
Initialize the internal cache names.BackingMapManager
realizeBackingMapManager(ConfigurableCacheFactory factory)
Realize aBackingMapManager
to be scoped by the specifiedConfigurableCacheFactory
.void
setAddressProvider(ParameterizedBuilder<AddressProvider> addrProviderBuilder)
Set the address provider.void
setFederatedLoading(boolean fFederatedLoading)
Set the flag to indicate if the cache store load should be federated.void
setJournalcacheBackingMapScheme(BackingMapScheme scheme)
Set theBackingMapScheme
which builds the backing map for federation's internal caches.void
setJournalcacheHighunits(int nHighUnits)
Deprecated.void
setJournalcacheHighunits(String sHighUnits)
Set the high-units limit for the federation journal cache.void
setLoadBalancer(FederatedServiceLoadBalancerBuilder bldrLoadBalancer)
Set the load-balancer builder.void
setParticipantDestination(String sParticipantDest)
Set the Participant destination name.void
setSendOldValue(boolean fSendOldValue)
Set the flag to indicate if the old value should be sent when replicating.void
setSocketProviderBuilder(SocketProviderBuilder builder)
Set theSocketProviderBuilder
.void
setTopologies(List<FederatedScheme.TopologyReference> listRefs)
Set the list of topology references.protected void
validate()
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:
getServiceType
in interfaceServiceScheme
- Overrides:
getServiceType
in classDistributedScheme
- Returns:
- the service type
-
realizeBackingMapManager
public BackingMapManager realizeBackingMapManager(ConfigurableCacheFactory factory)
Description copied from class:AbstractCachingScheme
Realize aBackingMapManager
to be scoped by the specifiedConfigurableCacheFactory
.- Specified by:
realizeBackingMapManager
in interfaceBackingMapManagerBuilder
- Overrides:
realizeBackingMapManager
in classAbstractCachingScheme<com.tangosol.internal.net.service.grid.PartitionedCacheDependencies>
- Parameters:
factory
- theConfigurableCacheFactory
- Returns:
- a
BackingMapManager
-
validate
protected void validate()
Validate the properties.- Overrides:
validate
in 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 theBackingMapScheme
which 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 theBackingMapScheme
which 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
-
-