@Override public List<String> getKnownHosts() { List<String> hosts = new ArrayList<String>(); for (CassandraHost cassandraHost : connectionManager.getHosts()) { hosts.add(cassandraHost.toString()); } return hosts; }
/* (non-Javadoc) * @see me.prettyprint.cassandra.service.Cluster#getKnownPoolHosts(boolean) */ @Override public Set<CassandraHost> getKnownPoolHosts(boolean refresh) { if (refresh || knownPoolHosts == null) { knownPoolHosts = connectionManager.getHosts(); if (log.isInfoEnabled()) { log.info("found knownPoolHosts: {}", knownPoolHosts); } } return knownPoolHosts; }
@Override public int getNumPools() { return connectionManager.getHosts().size(); }