Module org.elasticsearch.server
Record Class ClusterFormationFailureHelper.ClusterFormationState
java.lang.Object
java.lang.Record
org.elasticsearch.cluster.coordination.ClusterFormationFailureHelper.ClusterFormationState
- All Implemented Interfaces:
Writeable
- Enclosing class:
ClusterFormationFailureHelper
public static record ClusterFormationFailureHelper.ClusterFormationState(List<String> initialMasterNodesSetting, ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView, List<TransportAddress> resolvedAddresses, List<DiscoveryNode> foundPeers, Set<DiscoveryNode> mastersOfPeers, boolean hasDiscoveredQuorum, StatusInfo statusInfo, List<JoinStatus> inFlightJoinStatuses)
extends Record
implements Writeable
This record provides node state information that can be used to determine why cluster formation has failed.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Constructor Summary
ConstructorsConstructorDescriptionClusterFormationState(List<String> initialMasterNodesSetting, ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView, List<TransportAddress> resolvedAddresses, List<DiscoveryNode> foundPeers, Set<DiscoveryNode> mastersOfPeers, boolean hasDiscoveredQuorum, StatusInfo statusInfo, List<JoinStatus> inFlightJoinStatuses) Creates an instance of aClusterFormationStaterecord class.ClusterFormationState(Settings settings, ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView, List<TransportAddress> resolvedAddresses, List<DiscoveryNode> foundPeers, Set<DiscoveryNode> mastersOfPeers, ElectionStrategy electionStrategy, StatusInfo statusInfo, List<JoinStatus> inFlightJoinStatuses) -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theclusterFormationClusterStateViewrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefoundPeersrecord component.This method provides a human-readable String describing why cluster formation failed.booleanReturns the value of thehasDiscoveredQuorumrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theinFlightJoinStatusesrecord component.Returns the value of theinitialMasterNodesSettingrecord component.Returns the value of themastersOfPeersrecord component.readFrom(StreamInput in) Returns the value of theresolvedAddressesrecord component.Returns the value of thestatusInforecord component.final StringtoString()Returns a string representation of this record class.voidwriteTo(StreamOutput out) Write this into the StreamOutput.
-
Constructor Details
-
ClusterFormationState
public ClusterFormationState(Settings settings, ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView, List<TransportAddress> resolvedAddresses, List<DiscoveryNode> foundPeers, Set<DiscoveryNode> mastersOfPeers, ElectionStrategy electionStrategy, StatusInfo statusInfo, List<JoinStatus> inFlightJoinStatuses) -
ClusterFormationState
public ClusterFormationState(List<String> initialMasterNodesSetting, ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView, List<TransportAddress> resolvedAddresses, List<DiscoveryNode> foundPeers, Set<DiscoveryNode> mastersOfPeers, boolean hasDiscoveredQuorum, StatusInfo statusInfo, List<JoinStatus> inFlightJoinStatuses) Creates an instance of aClusterFormationStaterecord class.- Parameters:
initialMasterNodesSetting- the value for theinitialMasterNodesSettingrecord componentclusterFormationClusterStateView- the value for theclusterFormationClusterStateViewrecord componentresolvedAddresses- the value for theresolvedAddressesrecord componentfoundPeers- the value for thefoundPeersrecord componentmastersOfPeers- the value for themastersOfPeersrecord componenthasDiscoveredQuorum- the value for thehasDiscoveredQuorumrecord componentstatusInfo- the value for thestatusInforecord componentinFlightJoinStatuses- the value for theinFlightJoinStatusesrecord component
-
-
Method Details
-
readFrom
public static ClusterFormationFailureHelper.ClusterFormationState readFrom(StreamInput in) throws IOException - Throws:
IOException
-
getDescription
This method provides a human-readable String describing why cluster formation failed.- Returns:
- A human-readable String describing why cluster formation failed
-
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
initialMasterNodesSetting
Returns the value of theinitialMasterNodesSettingrecord component.- Returns:
- the value of the
initialMasterNodesSettingrecord component
-
clusterFormationClusterStateView
public ClusterFormationFailureHelper.ClusterFormationClusterStateView clusterFormationClusterStateView()Returns the value of theclusterFormationClusterStateViewrecord component.- Returns:
- the value of the
clusterFormationClusterStateViewrecord component
-
resolvedAddresses
Returns the value of theresolvedAddressesrecord component.- Returns:
- the value of the
resolvedAddressesrecord component
-
foundPeers
Returns the value of thefoundPeersrecord component.- Returns:
- the value of the
foundPeersrecord component
-
mastersOfPeers
Returns the value of themastersOfPeersrecord component.- Returns:
- the value of the
mastersOfPeersrecord component
-
hasDiscoveredQuorum
public boolean hasDiscoveredQuorum()Returns the value of thehasDiscoveredQuorumrecord component.- Returns:
- the value of the
hasDiscoveredQuorumrecord component
-
statusInfo
Returns the value of thestatusInforecord component.- Returns:
- the value of the
statusInforecord component
-
inFlightJoinStatuses
Returns the value of theinFlightJoinStatusesrecord component.- Returns:
- the value of the
inFlightJoinStatusesrecord component
-