Do not allow overrides of onReceive{Command,Recover}
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / test / java / org / opendaylight / controller / cluster / datastore / ShardTest.java
index 9fd33b217d9825e02bc4dbb1cc83edbc286afbfe..f639c8db49c659921f1f472284eb8812ad95b485 100644 (file)
@@ -174,7 +174,7 @@ public class ShardTest extends AbstractShardTest {
                     // 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
@@ -197,7 +197,7 @@ public class ShardTest extends AbstractShardTest {
 
                                 onFirstElectionTimeout.countDown();
                             } else {
-                                super.onReceiveCommand(message);
+                                super.handleCommand(message);
                             }
                         }
                     };
@@ -286,7 +286,7 @@ public class ShardTest extends AbstractShardTest {
                 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();
@@ -301,7 +301,7 @@ public class ShardTest extends AbstractShardTest {
 
                                 onFirstElectionTimeout.countDown();
                             } else {
-                                super.onReceiveCommand(message);
+                                super.handleCommand(message);
                             }
                         }
                     };
@@ -2011,8 +2011,8 @@ public class ShardTest extends AbstractShardTest {
                 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();