Add an assertion to ZenDiscovery checking that local node is never elected if pings indicate an active master

This commit is contained in:
Boaz Leskes 2014-08-29 17:07:24 +02:00
parent 680fb36637
commit ed5b2e0e35
1 changed files with 2 additions and 0 deletions

View File

@ -965,6 +965,8 @@ public class ZenDiscovery extends AbstractLifecycleComponent<Discovery> implemen
return null;
}
} else {
assert !pingMasters.contains(localNode) : "local node should never be elected as master when other nodes indicate an active master";
// lets tie break between discovered nodes
return electMaster.electMaster(pingMasters);
}