Madan Jampani
Committed by Gerrit Code Review

Leadership: Rerun purge step when conflicting updates are detected

Change-Id: Iecf34a79688ff6d288f7bf17e0d99be35b6539e2
...@@ -577,6 +577,10 @@ public class DistributedLeadershipManager implements LeadershipService { ...@@ -577,6 +577,10 @@ public class DistributedLeadershipManager implements LeadershipService {
577 updatedCandidates.value(), 577 updatedCandidates.value(),
578 updatedCandidates.version(), 578 updatedCandidates.version(),
579 updatedCandidates.creationTime()))); 579 updatedCandidates.creationTime())));
580 + } else {
581 + // Conflicting update detected. Rerun purge to make sure
582 + // inactive candidates are evicted.
583 + rerunPurge.set(true);
580 } 584 }
581 } catch (Exception e) { 585 } catch (Exception e) {
582 log.debug("Failed to evict inactive candidates {} from " 586 log.debug("Failed to evict inactive candidates {} from "
......