RemoteListenable rl = node.getRemoteListenable(); List listenerNames = rl.list(); for (int j = 0; j < listenerNames.size(); j++) { String s = (String)listenerNames.get(j); if (s.equals(CSMART.getNodeListenerId())) return true;
if (node != null) { RemoteListenable rl = node.getRemoteListenable(); List listenerNames = rl.list(); for (int j = 0; j < listenerNames.size(); j++) { String s = (String)listenerNames.get(j); if (s.equals(CSMART.getNodeListenerId())) return true; } } else { if (log.isWarnEnabled()) log.warn("findListener got null RemoteProcess from appServer for node " + name);
  private boolean findListener(RemoteHost appServer, String name) {    try {      RemoteProcess node = appServer.getRemoteProcess(name);      RemoteListenable rl = node.getRemoteListenable();      List listenerNames = rl.list();      for (int j = 0; j < listenerNames.size(); j++) {        String s = (String)listenerNames.get(j);        if (s.equals(CSMART.getNodeListenerId()))           return true;      }    } catch (Exception e) {      if (log.isErrorEnabled()) {        log.error("Exception searching for CSMART listeners on process " + name, e);      }      // FIXME: Really should remove this from the active appSever list    }    return false;  }