Has anyone had any success with connecting to a Cassandra cluster using DBeaver Community Edition? I've tried to follow this post, but haven't had any success. I have to have authentication enabled, and I get an error saying:
Authentication error on host /x.x.x.x:9042: Host /x.x.x.x:9042 requires authentication, but no authenticator found in Cluster configuration
Overview. DBeaver EE supports Cassandra schema browser, data viewer and CQL queries execution. Also it supports various administrative tools. You can connect directly to a server or use SSH tunneling or SOCKS proxy.
The default transport port, which is used by Sterling B2B Integrator to connect to Cassandra. Default is 9042. The port for the thrift RPC service, which is used for client connections. The cqlsh client uses the RPC port to connect to Cassandra.
Users can access Cassandra through its nodes using Cassandra Query Language (CQL). CQL treats the database (Keyspace) as a container of tables. Programmers use cqlsh: a prompt to work with CQL or separate application language drivers. Clients approach any of the nodes for their read-write operations.
You can connect directly to a server or use SSH tunneling or SOCKS proxy. DBeaver uses DataStax Java driver 3.5.1 to operate with server. It supports Cassandra servers 2.x, 3.x or higher. You can browse, view, edit and filter Cassandra tables the same way as with regular (relational) tables.
In the Databases menu, click New Connection. In the Create new connection wizard that results, select the driver. On the next page of the wizard, click the driver properties tab. Enter values for authentication credentials and other properties required to connect to Cassandra.
To add the .jar, click Add File. In the create new driver dialog that appears, select the cdata.jdbc.cassandra.jar file, located in the lib subfolder of the installation directory. Click the Find Class button and select the CassandraDriver class from the results.
It supports Cassandra servers 2.x, 3.x or higher. You can browse, view, edit and filter Cassandra tables the same way as with regular (relational) tables. However, being a distributed key-value database, Cassandra doesn’t support any kind of referential integrity.
Erick Ramirez answer mostly worked for me. I did manage to get a connection, but I never figured out how to get dbeaver to properly work with dates. By default they were displayed in local time, and queries with filters on exact timestamps did not work.
What did work very well for me was the Cassandra integration in JetBrains Rider. (I guess it's the same as for JetBrains IntelliJ)
DataStax offers the JDBC driver from Magnitude (formerly Simba) to users at no cost so you should be able to use it with DBeaver.
These are the high-level steps for connecting to a Cassandra cluster with DBeaver:
In DBeaver, go to the Driver Manager and import the Simba JDBC driver as follows:
CassandraJDBC42.jar
file.com.simba.cassandra.jdbc42.Driver
.Cassandra
Generic
com.simba.cassandra.jdbc42.Driver
jdbc:cassandra://{host}[:{port}];AuthMech=1
(set authentication mechanism to 0
if your cluster doesn't have authentication enabled)9042
At this point, you should see Cassandra as one of the drivers in the list.
In DBeaver, create a new database connection as follows:
node_ip_address
(this could be any node in your cluster)9042
(or whatever you've set as rpc_port
in cassandra.yaml
)your_db_username
your_db_password
At this point, you should be able to browse the keyspaces and tables in your Cassandra cluster. Cheers!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With