Class MulticastDiscoveryStrategy
- java.lang.Object
-
- com.hazelcast.spi.discovery.AbstractDiscoveryStrategy
-
- com.hazelcast.spi.discovery.multicast.MulticastDiscoveryStrategy
-
- All Implemented Interfaces:
DiscoveryStrategy
public class MulticastDiscoveryStrategy extends AbstractDiscoveryStrategy
The multicastDiscoveryStrategy
.
-
-
Constructor Summary
Constructors Constructor Description MulticastDiscoveryStrategy(DiscoveryNode discoveryNode, ILogger logger, java.util.Map<java.lang.String,java.lang.Comparable> properties)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
Thestop
method is used to stop internal services, sockets or to destroy any kind of internal state.java.lang.Iterable<DiscoveryNode>
discoverNodes()
Returns a set of all discovered nodes based on the defined properties that were used to create theDiscoveryStrategy
instance.PartitionGroupStrategy
getPartitionGroupStrategy()
void
start()
Thestart
method is used to initialize internal state and perform any kind of startup procedure like multicast socket creation.-
Methods inherited from class com.hazelcast.spi.discovery.AbstractDiscoveryStrategy
discoverLocalMetadata, getLogger, getOrDefault, getOrDefault, getOrNull, getOrNull, getPartitionGroupStrategy, getProperties
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.hazelcast.spi.discovery.DiscoveryStrategy
getUnhealthyEndpoints, markEndpointAsUnhealthy
-
-
-
-
Constructor Detail
-
MulticastDiscoveryStrategy
public MulticastDiscoveryStrategy(DiscoveryNode discoveryNode, ILogger logger, java.util.Map<java.lang.String,java.lang.Comparable> properties)
-
-
Method Detail
-
start
public void start()
Description copied from interface:DiscoveryStrategy
Thestart
method is used to initialize internal state and perform any kind of startup procedure like multicast socket creation. The behavior of this method might change based on theDiscoveryNode
instance passed to theDiscoveryStrategyFactory
.- Specified by:
start
in interfaceDiscoveryStrategy
- Overrides:
start
in classAbstractDiscoveryStrategy
-
discoverNodes
public java.lang.Iterable<DiscoveryNode> discoverNodes()
Description copied from interface:DiscoveryStrategy
Returns a set of all discovered nodes based on the defined properties that were used to create theDiscoveryStrategy
instance.- Returns:
- a set of all discovered nodes
-
destroy
public void destroy()
Description copied from interface:DiscoveryStrategy
Thestop
method is used to stop internal services, sockets or to destroy any kind of internal state.- Specified by:
destroy
in interfaceDiscoveryStrategy
- Overrides:
destroy
in classAbstractDiscoveryStrategy
-
getPartitionGroupStrategy
public PartitionGroupStrategy getPartitionGroupStrategy()
- Specified by:
getPartitionGroupStrategy
in interfaceDiscoveryStrategy
- Overrides:
getPartitionGroupStrategy
in classAbstractDiscoveryStrategy
- Returns:
- a custom implementation of a
PartitionGroupStrategy
otherwisenull
in case of the default implementation is to be used
-
-