public class GridPluginComponent extends Object implements GridComponent
GridComponent.DiscoveryDataExchangeType
Constructor and Description |
---|
GridPluginComponent(PluginProvider plugin) |
Modifier and Type | Method and Description |
---|---|
Serializable |
collectDiscoveryData(UUID nodeId)
Gets discovery data object that will be sent to new node
during discovery process.
|
GridComponent.DiscoveryDataExchangeType |
discoveryDataType()
Gets unique component type to distinguish components providing discovery data.
|
void |
onDisconnected(IgniteFuture<?> reconnectFut)
Client disconnected callback.
|
void |
onDiscoveryDataReceived(UUID joiningNodeId,
UUID rmtNodeId,
Serializable data)
Receives discovery data object from remote nodes (called
on new node during discovery process).
|
void |
onKernalStart()
Callback that notifies that kernal has successfully started,
including all managers and processors.
|
void |
onKernalStop(boolean cancel)
Callback to notify that kernal is about to stop.
|
IgniteInternalFuture<?> |
onReconnected(boolean clusterRestarted)
Client reconnected callback.
|
PluginProvider |
plugin() |
void |
printMemoryStats()
Prints memory statistics (sizes of internal structures, etc.).
|
void |
start()
Starts grid component.
|
void |
stop(boolean cancel)
Stops grid component.
|
IgniteNodeValidationResult |
validateNode(ClusterNode node)
Validates that new node can join grid topology, this method is called on coordinator
node before new node joins topology.
|
public GridPluginComponent(PluginProvider plugin)
plugin
- Plugin provider.public PluginProvider plugin()
public void start() throws IgniteCheckedException
start
in interface GridComponent
IgniteCheckedException
- Throws in case of any errors.public void stop(boolean cancel) throws IgniteCheckedException
stop
in interface GridComponent
cancel
- If true
, then all ongoing tasks or jobs for relevant
components need to be cancelled.IgniteCheckedException
- Thrown in case of any errors.public void onKernalStart() throws IgniteCheckedException
onKernalStart
in interface GridComponent
IgniteCheckedException
- Thrown in case of any errors.public void onDisconnected(IgniteFuture<?> reconnectFut)
onDisconnected
in interface GridComponent
reconnectFut
- Reconnect future.public IgniteInternalFuture<?> onReconnected(boolean clusterRestarted)
onReconnected
in interface GridComponent
clusterRestarted
- Cluster restarted flag.public void onKernalStop(boolean cancel)
onKernalStop
in interface GridComponent
cancel
- Flag indicating whether jobs should be canceled.@Nullable public GridComponent.DiscoveryDataExchangeType discoveryDataType()
GridComponent.collectDiscoveryData(UUID)
.discoveryDataType
in interface GridComponent
@Nullable public Serializable collectDiscoveryData(UUID nodeId)
collectDiscoveryData
in interface GridComponent
nodeId
- ID of new node that joins topology.null
if there is nothing
to send for this component.public void onDiscoveryDataReceived(UUID joiningNodeId, UUID rmtNodeId, Serializable data)
onDiscoveryDataReceived
in interface GridComponent
joiningNodeId
- Joining node ID.rmtNodeId
- Remote node ID for which data is provided.data
- Discovery data object or null
if nothing was@Nullable public IgniteNodeValidationResult validateNode(ClusterNode node)
validateNode
in interface GridComponent
node
- Joining node.null
in case of success.public void printMemoryStats()
printMemoryStats
in interface GridComponent
Follow @ApacheIgnite
Ignite Fabric : ver. 1.9.0 Release Date : March 2 2017