// it does do a persist)
return new Shard(newShardBuilder()) {
@Override
- public void onReceiveCommand(final Object message) throws Exception {
+ public void handleCommand(final Object message) {
if(message instanceof ElectionTimeout && firstElectionTimeout) {
// Got the first ElectionTimeout. We don't forward it to the
// base Shard yet until we've sent the RegisterChangeListener
onFirstElectionTimeout.countDown();
} else {
- super.onReceiveCommand(message);
+ super.handleCommand(message);
}
}
};
public Shard create() throws Exception {
return new Shard(newShardBuilder()) {
@Override
- public void onReceiveCommand(final Object message) throws Exception {
+ public void handleCommand(final Object message) {
if(message instanceof ElectionTimeout && firstElectionTimeout) {
firstElectionTimeout = false;
final ActorRef self = getSelf();
onFirstElectionTimeout.countDown();
} else {
- super.onReceiveCommand(message);
+ super.handleCommand(message);
}
}
};
public Shard create() throws Exception {
return new Shard(newShardBuilder()) {
@Override
- public void onReceiveCommand(final Object message) throws Exception {
- super.onReceiveCommand(message);
+ public void handleCommand(final Object message) {
+ super.handleCommand(message);
if(message.equals(TX_COMMIT_TIMEOUT_CHECK_MESSAGE)) {
if(cleaupCheckLatch.get() != null) {
cleaupCheckLatch.get().countDown();