Allow passing of delay to the EntityOwnerElectionStrategy
[controller.git] / opendaylight / md-sal / sal-distributed-datastore / src / main / java / org / opendaylight / controller / cluster / datastore / entityownership / selectionstrategy / FirstCandidateSelectionStrategy.java
index a619035f35f9fc6963ab89e65579391bb7fc94c5..b009c3aff429e29693a7de30abdbb427f92652b2 100644 (file)
@@ -14,13 +14,12 @@ import java.util.Collection;
 /**
  * The FirstCandidateSelectionStrategy always selects the first viable candidate from the list of candidates
  */
-public class FirstCandidateSelectionStrategy implements EntityOwnerSelectionStrategy {
+public class FirstCandidateSelectionStrategy extends AbstractEntityOwnerSelectionStrategy {
 
-    public static final FirstCandidateSelectionStrategy INSTANCE = new FirstCandidateSelectionStrategy();
+    public static final FirstCandidateSelectionStrategy INSTANCE = new FirstCandidateSelectionStrategy(0L);
 
-    @Override
-    public long selectionDelayInMillis() {
-        return 0;
+    public FirstCandidateSelectionStrategy(long selectionDelayInMillis) {
+        super(selectionDelayInMillis);
     }
 
     @Override