Code Review
/
controller.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Calculate replicated log data size on recovery
[controller.git]
/
opendaylight
/
md-sal
/
sal-akka-raft
/
src
/
main
/
java
/
org
/
opendaylight
/
controller
/
cluster
/
raft
/
ReplicatedLog.java
diff --git
a/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/ReplicatedLog.java
b/opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/ReplicatedLog.java
index 82d0839bee772bd8efba88a8d1392ab1d336ff1c..8388eaf7436f251c63aa277024bf886f803153cb 100644
(file)
--- a/
opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/ReplicatedLog.java
+++ b/
opendaylight/md-sal/sal-akka-raft/src/main/java/org/opendaylight/controller/cluster/raft/ReplicatedLog.java
@@
-8,6
+8,7
@@
package org.opendaylight.controller.cluster.raft;
package org.opendaylight.controller.cluster.raft;
+import akka.japi.Procedure;
import java.util.List;
/**
import java.util.List;
/**
@@
-50,8
+51,9
@@
public interface ReplicatedLog {
* information
*
* @param index the index of the log entry
* information
*
* @param index the index of the log entry
+ * @return the adjusted index of the first log entry removed or -1 if log entry not found.
*/
*/
-
void
removeFrom(long index);
+
long
removeFrom(long index);
/**
/**
@@
-85,6
+87,8
@@
public interface ReplicatedLog {
*/
void appendAndPersist(final ReplicatedLogEntry replicatedLogEntry);
*/
void appendAndPersist(final ReplicatedLogEntry replicatedLogEntry);
+ void appendAndPersist(ReplicatedLogEntry replicatedLogEntry, Procedure<ReplicatedLogEntry> callback);
+
/**
*
* @param index the index of the log entry
/**
*
* @param index the index of the log entry