Package org.graylog2.cluster
Interface NodeService
- All Known Implementing Classes:
NodeServiceImpl
public interface NodeService
-
Method Summary
Modifier and TypeMethodDescriptionDeprecated.byNodeIds
(Collection<String> nodeIds) void
boolean
boolean
isOnlyLeader
(NodeId nodeIde) default void
markAsAlive
(NodeId node, boolean isLeader, URI restTransportAddress) void
markAsAlive
(NodeId node, boolean isLeader, URI restTransportAddress, String clusterAddress) default boolean
registerServer
(String nodeId, boolean isLeader, URI httpPublishUri, String hostname) boolean
registerServer
(String nodeId, boolean isLeader, URI httpPublishUri, String clusterUri, String hostname) type()
-
Method Details
-
type
Node.Type type() -
registerServer
-
registerServer
-
byNodeId
- Throws:
NodeNotFoundException
-
byNodeId
- Throws:
NodeNotFoundException
-
byNodeIds
-
allActive
-
allActive
Deprecated.Please use theallActive(Node.Type)
method and provide explicit type of the node. Otherwise, the implementation will fall back totype()
and provide only nodes of this type. -
dropOutdated
void dropOutdated() -
markAsAlive
void markAsAlive(NodeId node, boolean isLeader, URI restTransportAddress, String clusterAddress) throws NodeNotFoundException - Throws:
NodeNotFoundException
-
markAsAlive
default void markAsAlive(NodeId node, boolean isLeader, URI restTransportAddress) throws NodeNotFoundException - Throws:
NodeNotFoundException
-
isOnlyLeader
-
isAnyLeaderPresent
boolean isAnyLeaderPresent()
-