return false;
}
private void processHostEvent(VcEventType type, Event e) throws Exception {
logger.info("Received host event " + e);
HostEvent he = (HostEvent) e;
String hostName = he.getHost().getName();
List<NodeEntity> nodes = clusterEntityMgr.getNodesByHost(hostName);
switch (type) {
case HostConnected:
case EnteredMaintenanceMode:
case ExitMaintenanceMode:
case HostDisconnected: {
Thread.sleep(2000);
VcHost host = VcCache.getIgnoreMissing(he.getHost().getHost());
host.update();
for (NodeEntity node : nodes) {
String moId = node.getMoId();
if (moId == null) {
continue;