} else {
nodeDos = nodeDao.listByMultiId(identities);
if (nodeDos.isEmpty()) {
String exceptionCause = "couldn't query any node by nodeIds:" + Arrays.toString(identities);
logger.error("ERROR ## " + exceptionCause);
throw new ManagerException(exceptionCause);
}
}
// 验证zk的node信息
List<Long> nodeIds = arbitrateManageService.nodeEvent().liveNodes();
for (NodeDO nodeDo : nodeDos) {
if (nodeIds.contains(nodeDo.getId())) {
nodeDo.setStatus(NodeStatus.START);
} else {
nodeDo.setStatus(NodeStatus.STOP);
}
}
nodes = doToModel(nodeDos);
} catch (Exception e) {
logger.error("ERROR ## query nodes has an exception!");
throw new ManagerException(e);
}
return nodes;
}