protected class MockQuorumFixture.MockQuorum.MockQuorumWatcher extends AbstractQuorum.QuorumWatcherBase implements QuorumListener
MockQuorumFixture2
to the MockQuorumFixture.MockQuorum
.
Note: This relies on the QuorumEvent
mechanism. If there are
errors, they will be logged rather than propagated. This actually
mimics what happens if a client spams zookeeper with some bad data.
The errors will be observed in the QuorumWatcher of the clients
monitoring that quorum.
logicalServiceId
Modifier | Constructor and Description |
---|---|
protected |
MockQuorumFixture.MockQuorum.MockQuorumWatcher(String logicalServiceUUID) |
Modifier and Type | Method and Description |
---|---|
void |
notify(QuorumEvent e)
Propagate state change to our quorum.
|
protected void |
start()
Method is invoked by
AbstractQuorum.start(QuorumClient) and
provides the QuorumWatcher with an opportunity to setup
discovery (such as zookeeper watchers) and read the initial state of
the distributed quorum, causing it to be reflected on the
AbstractQuorum internal state. |
protected void |
terminate()
Method is invoked by
AbstractQuorum.terminate() and provides
the QuorumWatcher with an opportunity to terminate
asynchronous processing and tear down any resources it may be using. |
castVote, clearToken, doAction, memberAdd, memberRemove, pipelineAdd, pipelineRemove, serviceJoin, serviceLeave, setToken, withdrawVote
protected MockQuorumFixture.MockQuorum.MockQuorumWatcher(String logicalServiceUUID)
public void notify(QuorumEvent e)
notify
in interface QuorumListener
protected void start()
AbstractQuorum.QuorumWatcherBase
AbstractQuorum.start(QuorumClient)
and
provides the QuorumWatcher
with an opportunity to setup
discovery (such as zookeeper watchers) and read the initial state of
the distributed quorum, causing it to be reflected on the
AbstractQuorum
internal state.start
in class AbstractQuorum.QuorumWatcherBase
protected void terminate()
AbstractQuorum.QuorumWatcherBase
AbstractQuorum.terminate()
and provides
the QuorumWatcher
with an opportunity to terminate
asynchronous processing and tear down any resources it may be using.terminate
in class AbstractQuorum.QuorumWatcherBase
Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.