Package io.microraft.exception
Class MismatchingRaftGroupMembersCommitIndexException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
io.microraft.exception.RaftException
io.microraft.exception.MismatchingRaftGroupMembersCommitIndexException
- All Implemented Interfaces:
Serializable
Thrown when a membership change is triggered with an expected group members
commit index that doesn't match the current group members commit index in the
local state of the Raft group leader. A group members commit index is the
Raft log index at which the current Raft group member list is committed.
- See Also:
-
Constructor Summary
ConstructorDescriptionMismatchingRaftGroupMembersCommitIndexException
(long commitIndex, Collection<RaftEndpoint> members) Creates an instance of this exception -
Method Summary
Modifier and TypeMethodDescriptionlong
Returns the commit index of the current Raft group members.Returns the current Raft group members knwon by the Raft nodetoString()
Methods inherited from class io.microraft.exception.RaftException
getLeader
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Constructor Details
-
MismatchingRaftGroupMembersCommitIndexException
public MismatchingRaftGroupMembersCommitIndexException(long commitIndex, Collection<RaftEndpoint> members) Creates an instance of this exception- Parameters:
commitIndex
- the commit index of the current Raft group membersmembers
- the current Raft group members knwon by the Raft node
-
-
Method Details
-
getCommitIndex
public long getCommitIndex()Returns the commit index of the current Raft group members.- Returns:
- the commit index of the current Raft group members.
-
getMembers
Returns the current Raft group members knwon by the Raft node- Returns:
- the current Raft group members knwon by the Raft node
-
toString
- Overrides:
toString
in classRaftException
-