String username = CMBProperties.getInstance().getCassandraUsername();
String password = CMBProperties.getInstance().getCassandraPassword();
for (String k : keyspaceNames) {
ConnectionPoolConfigurationImpl connectionPoolConfiguration = new ConnectionPoolConfigurationImpl("CMBAstyananxConnectionPool")
.setMaxConnsPerHost(CMBProperties.getInstance().getAstyanaxMaxConnectionsPerNode())
.setSocketTimeout(CMBProperties.getInstance().getCassandraThriftSocketTimeOutMS())
.setConnectTimeout(CMBProperties.getInstance().getAstyanaxConnectionWaitTimeOutMS())
.setSeeds(AbstractDurablePersistence.CLUSTER_URL);
if (username != null && password != null) {
connectionPoolConfiguration.setAuthenticationCredentials(new SimpleAuthenticationCredentials(username, password));
}
if (dataCenter != null && !dataCenter.equals("")) {
connectionPoolConfiguration.setLocalDatacenter(dataCenter);
}
AstyanaxContext<Keyspace> context = new AstyanaxContext.Builder()
.forCluster(CLUSTER_NAME)
.forKeyspace(k)