Class TransportConfigurationBuilder
java.lang.Object
org.infinispan.configuration.global.TransportConfigurationBuilder
- All Implemented Interfaces:
Builder<TransportConfiguration>,GlobalConfigurationChildBuilder
public class TransportConfigurationBuilder
extends Object
implements Builder<TransportConfiguration>
Configures the transport used for network communications across the cluster.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionaddProperty(String key, Object value) Configuration for the asynchronous operations thread poolConfiguration for the blocking thread poolbuild()Builds aGlobalConfigurationobject using the settings applied to this builderClears the transport propertiesclusterName(String clusterName) Defines the name of the cluster.create()Create the configuration beandefaultCacheName(String defaultCacheName) Sets the name of the cache that acts as the default cache and is returned byEmbeddedCacheManager.getCache().distributedSyncTimeout(long distributedSyncTimeout) Timeout for coordinating cluster formation when nodes join or leave the cluster.distributedSyncTimeout(long distributedSyncTimeout, TimeUnit unit) Timeout for coordinating cluster formation when nodes join or leave the cluster.Configuration for the expiration thread poolprotected GlobalConfigurationBuildergetProperty(String key) Global state configurationinitialClusterSize(int clusterSize) Sets the number of nodes that need to join before the cache container can start.initialClusterTimeout(long initialClusterTimeout, TimeUnit unit) Sets the timeout for the initial cluster to form.jgroups()jmx()Global JMX configuration.Configuration for the listener thread poolThe id of the machine where this node runs.metrics()Global metrics configuration.modules()Global modules configurationName of the current node.Configuration for the non blocking thread poolConfiguration for the persistence thread poolThe id of the rack where this node runs.raftMember(String member) Adds a single member to theraft-members.raftMembers(String... members) Adds multiple members to theraft-members.raftMembers(Collection<String> members) Adds multiple members to theraft-members.read(TransportConfiguration template, Combine combine) Reads the configuration from an already created configuration bean into this builder.remoteExecutor(String threadPoolName) removeProperty(String key) security()Security-related configurationGlobal serialization (i.e.shutdown()Shutdown configurationsite()Cross-site replication configurationThe id of the site where this node runs.Configuration for the state-transfer thread pooltoString()Transport-related (i.e.Class that represents a network transport.transportExecutor(String threadPoolName) Deprecated, for removal: This API element is subject to removal in a future version.voidvalidate()Validate the data in this builder before building the configuration beanwithProperties(Properties properties) Sets transport propertiesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.infinispan.configuration.global.GlobalConfigurationChildBuilder
globalJmxStatistics
-
Field Details
-
DEFAULT_TRANSPORT
- See Also:
-
-
Method Details
-
attributes
- Specified by:
attributesin interfaceBuilder<TransportConfiguration>
-
clusterName
Defines the name of the cluster. Nodes only connect to clusters sharing the same name.- Parameters:
clusterName-
-
machineId
The id of the machine where this node runs. Used for server hinting . -
rackId
The id of the rack where this node runs. Used for server hinting . -
siteId
The id of the site where this node runs. Used for server hinting . -
stack
-
distributedSyncTimeout
Timeout for coordinating cluster formation when nodes join or leave the cluster.- Parameters:
distributedSyncTimeout-- Returns:
-
distributedSyncTimeout
public TransportConfigurationBuilder distributedSyncTimeout(long distributedSyncTimeout, TimeUnit unit) Timeout for coordinating cluster formation when nodes join or leave the cluster.- Parameters:
distributedSyncTimeout-- Returns:
-
initialClusterSize
Sets the number of nodes that need to join before the cache container can start. The default is to start immediately without waiting. -
initialClusterTimeout
public TransportConfigurationBuilder initialClusterTimeout(long initialClusterTimeout, TimeUnit unit) Sets the timeout for the initial cluster to form. Defaults to 1 minute -
transport
Class that represents a network transport. Must implement org.infinispan.remoting.transport.Transport NOTE: Currently Infinispan will not use the object instance, but instead instantiate a new instance of the class. Therefore, do not expect any state to survive, and provide a no-args constructor to any instance.- Parameters:
transport- transport instance
-
nodeName
Name of the current node. This is a friendly name to make logs, etc. make more sense. Defaults to a combination of host name and a random number (to differentiate multiple nodes on the same host)- Parameters:
nodeName-
-
withProperties
Sets transport properties- Parameters:
properties-- Returns:
- this TransportConfig
-
clearProperties
Clears the transport properties- Returns:
- this TransportConfig
-
addProperty
-
removeProperty
-
getProperty
-
transportThreadPool
-
remoteCommandThreadPool
-
validate
public void validate()Description copied from interface:BuilderValidate the data in this builder before building the configuration bean- Specified by:
validatein interfaceBuilder<TransportConfiguration>
-
jgroups
-
create
Description copied from interface:BuilderCreate the configuration bean- Specified by:
createin interfaceBuilder<TransportConfiguration>- Returns:
-
defaultTransport
-
transportExecutor
@Deprecated(forRemoval=true) public TransportConfigurationBuilder transportExecutor(String threadPoolName) Deprecated, for removal: This API element is subject to removal in a future version. -
remoteExecutor
-
raftMember
Adds a single member to theraft-members.- Parameters:
member- The member to add
-
raftMembers
Adds multiple members to theraft-members.- Parameters:
members- The members to add
-
raftMembers
Adds multiple members to theraft-members.- Parameters:
members- The members to add
-
read
Description copied from interface:BuilderReads the configuration from an already created configuration bean into this builder. Returns an appropriate builder to allow fluent configuration- Specified by:
readin interfaceBuilder<TransportConfiguration>- Parameters:
template- the configuration from which to "clone" this config if needed.combine- the way attributes and children of this instance and the template should be combined.
-
getTransport
-
toString
-
getGlobalConfig
-
transport
Description copied from interface:GlobalConfigurationChildBuilderTransport-related (i.e. clustering) configuration- Specified by:
transportin interfaceGlobalConfigurationChildBuilder
-
metrics
Description copied from interface:GlobalConfigurationChildBuilderGlobal metrics configuration.- Specified by:
metricsin interfaceGlobalConfigurationChildBuilder
-
jmx
Description copied from interface:GlobalConfigurationChildBuilderGlobal JMX configuration.- Specified by:
jmxin interfaceGlobalConfigurationChildBuilder
-
globalState
Description copied from interface:GlobalConfigurationChildBuilderGlobal state configuration- Specified by:
globalStatein interfaceGlobalConfigurationChildBuilder
-
serialization
Description copied from interface:GlobalConfigurationChildBuilderGlobal serialization (i.e. marshalling) configuration- Specified by:
serializationin interfaceGlobalConfigurationChildBuilder
-
listenerThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the listener thread pool- Specified by:
listenerThreadPoolin interfaceGlobalConfigurationChildBuilder
-
asyncThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the asynchronous operations thread pool- Specified by:
asyncThreadPoolin interfaceGlobalConfigurationChildBuilder
-
expirationThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the expiration thread pool- Specified by:
expirationThreadPoolin interfaceGlobalConfigurationChildBuilder
-
persistenceThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the persistence thread pool- Specified by:
persistenceThreadPoolin interfaceGlobalConfigurationChildBuilder
-
stateTransferThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the state-transfer thread pool- Specified by:
stateTransferThreadPoolin interfaceGlobalConfigurationChildBuilder
-
blockingThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the blocking thread pool- Specified by:
blockingThreadPoolin interfaceGlobalConfigurationChildBuilder
-
nonBlockingThreadPool
Description copied from interface:GlobalConfigurationChildBuilderConfiguration for the non blocking thread pool- Specified by:
nonBlockingThreadPoolin interfaceGlobalConfigurationChildBuilder
-
security
Description copied from interface:GlobalConfigurationChildBuilderSecurity-related configuration- Specified by:
securityin interfaceGlobalConfigurationChildBuilder
-
shutdown
Description copied from interface:GlobalConfigurationChildBuilderShutdown configuration- Specified by:
shutdownin interfaceGlobalConfigurationChildBuilder
-
site
Description copied from interface:GlobalConfigurationChildBuilderCross-site replication configuration- Specified by:
sitein interfaceGlobalConfigurationChildBuilder
-
modules
Description copied from interface:GlobalConfigurationChildBuilderGlobal modules configuration- Specified by:
modulesin interfaceGlobalConfigurationChildBuilder
-
defaultCacheName
Description copied from interface:GlobalConfigurationChildBuilderSets the name of the cache that acts as the default cache and is returned byEmbeddedCacheManager.getCache(). Not- Specified by:
defaultCacheNamein interfaceGlobalConfigurationChildBuilder
-
build
Description copied from interface:GlobalConfigurationChildBuilderBuilds aGlobalConfigurationobject using the settings applied to this builder- Specified by:
buildin interfaceGlobalConfigurationChildBuilder
-