Remove snapshot after startup and fix related bug
[controller.git] / opendaylight / md-sal / sal-akka-raft / src / main / java / org / opendaylight / controller / cluster / raft / ConfigParams.java
index 4245cf10f778fc81fe3181b0db5d9b825ea23a4c..c63deae7171904638c3315798b2d5332ae85a442 100644 (file)
@@ -7,6 +7,8 @@
  */
 package org.opendaylight.controller.cluster.raft;
 
+import javax.annotation.Nonnull;
+import org.opendaylight.controller.cluster.raft.policy.RaftPolicy;
 import scala.concurrent.duration.FiniteDuration;
 
 /**
@@ -75,5 +77,31 @@ public interface ConfigParams {
      * The interval in which the leader needs to check itself if its isolated
      * @return FiniteDuration
      */
-    FiniteDuration getIsolatedCheckInterval();
+    long getIsolatedCheckIntervalInMillis();
+
+
+    /**
+     * The multiplication factor to be used to determine shard election timeout. The election timeout
+     * is determined by multiplying the election timeout factor with the heartbeat duration.
+     */
+    long getElectionTimeoutFactor();
+
+
+    /**
+     *
+     * @return An instance of org.opendaylight.controller.cluster.raft.policy.RaftPolicy or an instance of the
+     * DefaultRaftPolicy
+     */
+    RaftPolicy getRaftPolicy();
+
+    /**
+     * Returns the PeerAddressResolver.
+     */
+    @Nonnull PeerAddressResolver getPeerAddressResolver();
+
+    /**
+     * @return the RaftPolicy class used by this configuration
+     */
+    String getCustomRaftPolicyImplementationClass();
+
 }