Code Review
/
controller.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
BUG-2184 Fix subtree filtering for identity-ref leaves
[controller.git]
/
opendaylight
/
md-sal
/
sal-akka-raft
/
src
/
main
/
java
/
org
/
opendaylight
/
controller
/
cluster
/
raft
/
behaviors
/
RaftActorBehavior.java
diff --git
a/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/RaftActorBehavior.java
b/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/RaftActorBehavior.java
index 6811678aaa9cfeb820e1169d530e112e5174e3ce..ca2d916ecf619ae61b8b627c2e10181d075a187a 100644
(file)
--- a/
opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/RaftActorBehavior.java
+++ b/
opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/behaviors/RaftActorBehavior.java
@@
-24,7
+24,7
@@
import org.opendaylight.controller.cluster.raft.RaftState;
* In each of these behaviors the Raft Actor handles the same Raft messages
* differently.
*/
* In each of these behaviors the Raft Actor handles the same Raft messages
* differently.
*/
-public interface RaftActorBehavior {
+public interface RaftActorBehavior
extends AutoCloseable
{
/**
* Handle a message. If the processing of the message warrants a state
* change then a new state should be returned otherwise this method should
/**
* Handle a message. If the processing of the message warrants a state
* change then a new state should be returned otherwise this method should
@@
-36,4
+36,17
@@
public interface RaftActorBehavior {
* @return The new state or self (this)
*/
RaftState handleMessage(ActorRef sender, Object message);
* @return The new state or self (this)
*/
RaftState handleMessage(ActorRef sender, Object message);
+
+ /**
+ * The state associated with a given behavior
+ *
+ * @return
+ */
+ RaftState state();
+
+ /**
+ *
+ * @return
+ */
+ String getLeaderId();
}
}