public static class AdvancedNetworkConfig.MemberNetworkingView extends NetworkConfig
NetworkConfig
Facade used during bootstrap to hide if-logic between the two networking configuration approachesDEFAULT_PORT
getMemcacheProtocolConfig, getRestApiConfig, setMemcacheProtocolConfig, setRestApiConfig
public int getPort()
NetworkConfig
getPort
in class NetworkConfig
NetworkConfig.setPort(int)
public NetworkConfig setPort(int port)
NetworkConfig
setPort
in class NetworkConfig
port
- the port the Hazelcast member will try to bind onNetworkConfig.getPort()
,
for more information
public int getPortCount()
NetworkConfig
getPortCount
in class NetworkConfig
NetworkConfig.setPortCount(int)
,
for more information
public NetworkConfig setPortCount(int portCount)
NetworkConfig
setPortCount
in class NetworkConfig
portCount
- the maximum number of ports allowed to usefor more information
public boolean isPortAutoIncrement()
NetworkConfig
isPortAutoIncrement
in class NetworkConfig
NetworkConfig.setPortAutoIncrement(boolean)
public NetworkConfig setPortAutoIncrement(boolean portAutoIncrement)
NetworkConfig
If you explicitly want to control the port a Hazelcast member is going to use, you probably want to set
portAutoincrement to false. In this case, the Hazelcast member is going to try the port NetworkConfig.setPort(int)
and if the port is not free, the member will not start and throw an exception.
If this value is set to true, Hazelcast will start at the port specified by NetworkConfig.setPort(int)
and will try
until it finds a free port, or until it runs out of ports to try NetworkConfig.setPortCount(int)
.
setPortAutoIncrement
in class NetworkConfig
portAutoIncrement
- the portAutoIncrement to setNetworkConfig.isPortAutoIncrement()
,
NetworkConfig.setPortCount(int)
,
NetworkConfig.setPort(int)
public boolean isReuseAddress()
isReuseAddress
in class NetworkConfig
public NetworkConfig setReuseAddress(boolean reuseAddress)
NetworkConfig
When should setReuseAddress(true) be used?
When the member is shutdown, the server socket port will be in TIME_WAIT state for the next 2 minutes or so. If you start the member right after shutting it down, you may not be able to bind to the same port because it is in TIME_WAIT state. if you set reuseAddress=true then TIME_WAIT will be ignored and you will be able to bind to the same port again.
This property should not be set to true on the Windows platform: see
setReuseAddress
in class NetworkConfig
public Collection<String> getOutboundPortDefinitions()
getOutboundPortDefinitions
in class NetworkConfig
public NetworkConfig setOutboundPortDefinitions(Collection<String> outboundPortDefs)
setOutboundPortDefinitions
in class NetworkConfig
public NetworkConfig addOutboundPortDefinition(String portDef)
addOutboundPortDefinition
in class NetworkConfig
public Collection<Integer> getOutboundPorts()
getOutboundPorts
in class NetworkConfig
public NetworkConfig setOutboundPorts(Collection<Integer> outboundPorts)
setOutboundPorts
in class NetworkConfig
public NetworkConfig addOutboundPort(int port)
addOutboundPort
in class NetworkConfig
public InterfacesConfig getInterfaces()
getInterfaces
in class NetworkConfig
public NetworkConfig setInterfaces(InterfacesConfig interfaces)
setInterfaces
in class NetworkConfig
interfaces
- the interfaces to setpublic JoinConfig getJoin()
NetworkConfig
JoinConfig
.getJoin
in class NetworkConfig
public NetworkConfig setJoin(JoinConfig join)
setJoin
in class NetworkConfig
join
- the join to setpublic String getPublicAddress()
getPublicAddress
in class NetworkConfig
public NetworkConfig setPublicAddress(String publicAddress)
NetworkConfig
setPublicAddress
in class NetworkConfig
public SocketInterceptorConfig getSocketInterceptorConfig()
NetworkConfig
SocketInterceptorConfig
. The value can be null
if no socket interception is needed.getSocketInterceptorConfig
in class NetworkConfig
NetworkConfig.setSocketInterceptorConfig(SocketInterceptorConfig)
public NetworkConfig setSocketInterceptorConfig(SocketInterceptorConfig socketInterceptorConfig)
NetworkConfig
SocketInterceptorConfig
. The value can be null
if no socket interception is needed.setSocketInterceptorConfig
in class NetworkConfig
socketInterceptorConfig
- the SocketInterceptorConfig to setpublic SymmetricEncryptionConfig getSymmetricEncryptionConfig()
NetworkConfig
SymmetricEncryptionConfig
. The value can be null
which means that no symmetric encryption should
be used.getSymmetricEncryptionConfig
in class NetworkConfig
public NetworkConfig setSymmetricEncryptionConfig(SymmetricEncryptionConfig symmetricEncryptionConfig)
NetworkConfig
SymmetricEncryptionConfig
. The value can be null
if no symmetric encryption should be used.setSymmetricEncryptionConfig
in class NetworkConfig
symmetricEncryptionConfig
- the SymmetricEncryptionConfig to setNetworkConfig.getSymmetricEncryptionConfig()
public SSLConfig getSSLConfig()
NetworkConfig
SSLConfig
. It is possible that null is returned if no SSLConfig has been set.getSSLConfig
in class NetworkConfig
NetworkConfig.setSSLConfig(SSLConfig)
public NetworkConfig setSSLConfig(SSLConfig sslConfig)
NetworkConfig
SSLConfig
. null value indicates that no SSLConfig should be used.setSSLConfig
in class NetworkConfig
sslConfig
- the SSLConfigNetworkConfig.getSSLConfig()
public MemberAddressProviderConfig getMemberAddressProviderConfig()
getMemberAddressProviderConfig
in class NetworkConfig
public NetworkConfig setMemberAddressProviderConfig(MemberAddressProviderConfig memberAddressProviderConfig)
setMemberAddressProviderConfig
in class NetworkConfig
public NetworkConfig setIcmpFailureDetectorConfig(IcmpFailureDetectorConfig icmpFailureDetectorConfig)
NetworkConfig
IcmpFailureDetectorConfig
. The value can be null
if this detector isn't needed.setIcmpFailureDetectorConfig
in class NetworkConfig
icmpFailureDetectorConfig
- the IcmpFailureDetectorConfig to setNetworkConfig.getIcmpFailureDetectorConfig()
public IcmpFailureDetectorConfig getIcmpFailureDetectorConfig()
NetworkConfig
IcmpFailureDetectorConfig
. It is possible that null is returned if no
IcmpFailureDetectorConfig has been set.getIcmpFailureDetectorConfig
in class NetworkConfig
NetworkConfig.setIcmpFailureDetectorConfig(IcmpFailureDetectorConfig)
public String toString()
toString
in class NetworkConfig
Copyright © 2021 Hazelcast, Inc.. All rights reserved.