public abstract class QuorumVote<V extends Vote,T> extends Object
Constructor and Description |
---|
QuorumVote(SimpleString name) |
Modifier and Type | Method and Description |
---|---|
abstract void |
allVotesCast(Topology voteTopology)
called by the
QuorumManager when all the votes have been cast and received. |
abstract Vote |
connected()
called by the
QuorumManager when one of the nodes in the quorum is
successfully connected to. |
abstract T |
getDecision()
get the decion of the vote
|
SimpleString |
getName()
the name of this quorum vote, used for identifying the correct
QuorumVoteHandler |
abstract Vote |
notConnected()
called by the
QuorumManager fails to connect to a node in the quorum. |
abstract void |
vote(V vote)
called by the
QuorumManager when a vote can be made, either from the
cluster or decided by itself. |
public QuorumVote(SimpleString name)
public abstract Vote connected()
QuorumManager
when one of the nodes in the quorum is
successfully connected to. The QuorumVote can then decide whether or not a decision can be made with just that information.public abstract Vote notConnected()
QuorumManager
fails to connect to a node in the quorum.
The QuorumVote can then decide whether or not a decision can be made with just that information however the node
cannot cannot be asked.public abstract void vote(V vote)
QuorumManager
when a vote can be made, either from the
cluster or decided by itself.vote
- the vote to make.public abstract T getDecision()
public abstract void allVotesCast(Topology voteTopology)
QuorumManager
when all the votes have been cast and received.voteTopology
- the topology of where the votes were sent.public SimpleString getName()
QuorumVoteHandler
Copyright © 2017 JBoss by Red Hat. All rights reserved.