/** * Build a new Cassandra cluster instance. * * @param hostsAndPorts * format: "host1:port1,host2,host3:port3". If no port is * specified, the {@link #DEFAULT_CASSANDRA_PORT} is used. * @param username * username to authenticate against Cassandra cluster * @param password * password to authenticate against Cassandra cluster * @return */ public static Cluster newCluster(String hostsAndPorts, String username, String password) { return newCluster(hostsAndPorts, username, password, null); }
/** * Create a {@link Cluster} instance. * * @param ci * @return * @since 0.4.0 */ protected Cluster createCluster(ClusterIdentifier ci) { return CqlUtils.newCluster(ci.hostsAndPorts, ci.username, ci.password, getConfiguration()); }