Interface ClusterNode

All Known Implementing Classes:
ClusterNodeImpl

public interface ClusterNode
  • Method Details

    • getNodeId

      String getNodeId()
      Retrieves a cluster-wide unique identifier for this node.

      Warning: Plugins should make no assumptions about this ID. That includes:

      • How long it is
      • What characters it contains
      • Whether it will be consistent across restarts. Don't persist long-term data against these IDs
      The value is guaranteed to be unique within the cluster. If the cluster is restarted, every node's ID will still be unique but will likely not be the same as the previous value.
      Returns:
      a cluster-wide unique identifier for this node
    • getNodeName

      String getNodeName()
      A long living cluster name that is defined by setting the system property cluster.node.name
      Returns:
      The value from the system property named above otherwise an empty string if the property is not set.
    • getLastHeartbeat

      @Internal Instant getLastHeartbeat()
      Returns:
      the time when the node has last checked-in as available
    • isLocal

      boolean isLocal()
      Returns:
      true if this represents the node the method is executed on, false otherwise
    • getDetails

      @ExperimentalApi Optional<ClusterNodeDetails> getDetails()
      Returns:
      extra details about the cluster node, the presence and completeness of this data is implementation specific, and not guaranteed