Reputation: 75
I have created a cluster called test with three nodes in my machine using ccm (All the nodes are UP). I want to access the cluster using Java API.
However, I get the error below:
All host(s) tried for query failed (tried: /127.0.0.1:9042(com.datastax.driver.core.exceptions.InvalidQueryException: unconfigured table schema_keyspaces)
Cassandra version : 3.11.4
cassandra driver core : 2.1.9
Part of my code :
public static void main(String args[])
{
//creating Cluster object
Cluster cluster = Cluster.builder().addContactPoint("127.0.0.1").build();
//Creating Session object
Session session = cluster.connect();
}
Anyway to resolve this?
Upvotes: 0
Views: 1280
Reputation: 16323
Version 2.1 of the Cassandra Java driver is not compatible with Apache Cassandra 3.11 (see the Compatibility Matrix).
You will need to upgrade to at least Java driver v3.0 to connect to a Cassandra 3.11 cluster. Cheers!
Upvotes: 0
Reputation: 26
Apparently schema_keyspaces isnt available in the specified cassandra version. I suggest to utilize the latest cassandra drivers , since that it is compatibility issue.
Upvotes: 1