- if (nodeConnections == null) return true;
- for (Node existingNode : nodeConnections.keySet()) {
- Set<InetAddress> controllers = nodeConnections.get(existingNode);
- if (controllers == null || controllers.size() == 0) continue;
- if (!controllers.contains(clusterServices.getMyAddress())) return false;
- }
- return true;
+ // Lets make it simple. The Cluster Coordinator is the master
+ return clusterServices.amICoordinator();