currently I'm starting a ClusterContext that way:
AstyanaxContext.Builder builder = new AstyanaxContext.Builder()
.forCluster(clusterName)
.forKeyspace(keyspaceName)
.withAstyanaxConfiguration(getAstyanaxProperties(properties))
.withConnectionPoolConfiguration(getConnectionPoolProperties(properties))
.withConnectionPoolMonitor(connectionPoolMonitor);
clusterContext = builder.buildCluster(ThriftFamilyFactory.getInstance());
clusterContext.start();
cluster = clusterContext.getEntity();
Running on a single node dev environment. I'm using a ClusterContext, because I also want to create a keyspace, column families etc.
Do I additionally also need to start up a KeyspaceContext? If so, for what purpose or is a single ClusterContext sufficient for keyspace/column family management and read/write scenarios?
If I do start up a KeyspaceContext, I see, according to the connection pool monitor, 2 hosts added and active. If I shutdown the single Cassandra node, I still see 1 marked as active, which is confusing.
Thanks.