apache-cassandra -by-cdata
This read-only MCP Server allows you to connect to Apache Cassandra data from Claude Desktop through CData JDBC Drivers. For full CRUD support, check out the first managed MCP platform: CData Connect AI (https://www.cdata.com/ai/).
claude mcp add --transport stdio cdatasoftware-apache-cassandra-mcp-server-by-cdata java -jar CDataMCP-jar-with-dependencies.jar /PATH/TO/apache-cassandra.prp
How to use
This MCP server exposes Apache Cassandra data via a read-only MCP interface built on top of the CData JDBC Driver for Cassandra. It allows LLMs and clients to discover available tables and columns and to run read-only SQL-like queries against Cassandra without requiring direct SQL access to the cluster. The server presents a set of tools named after the server and the data source, such as apache_cassandra_get_tables, apache_cassandra_get_columns, and apache_cassandra_run_query. To use it from Claude Desktop or any MCP client, configure the MCP server entry in the client’s mcpServers list, pointing to the Java jar and the generated .prp connection profile. Once configured, you can ask the AI to explore the schema, list tables, inspect columns, and execute SELECT queries to read live Cassandra data. Typical workflows include discovering available data via get_tables, drilling into the schema with get_columns, and running read-only queries with run_query to retrieve results in tabular form. The tools return results in CSV when listing tables/columns and standard JSON/tabular results for query outputs, enabling natural language questions such as “What are the top accounts by revenue this year?” or “Show me open tickets in the SUPPORT project.”
How to install
Prerequisites:
- Java Development Kit (JDK) 8 or newer installed on the host machine.
- Maven to build the MCP server from source.
- Access to the CData JDBC Driver for Apache Cassandra (licensing and setup per CData terms).
Installation steps:
- Build the MCP server jar from source:
- Ensure you have Java and Maven installed.
- Clone the repository and navigate into it.
- Run: mvn clean install
- This produces CDataMCP-jar-with-dependencies.jar in the target directory.
- Obtain and configure the CData JDBC Driver for Apache Cassandra per CData instructions (download and install the JDBC driver, then license it via the provided launcher as needed).
- Create the .prp configuration file for your Cassandra connection (apache-cassandra.prp) with your JDBC connection details, as described in the README: Prefix=cassandra ServerName=CDataCassandra ServerVersion=1.0 DriverPath=PATH\TO\cdata.jdbc.cassandra.jar DriverClass=cdata.jdbc.cassandra.CassandraDriver JdbcUrl=jdbc:cassandra:InitiateOAuth=GETANDREFRESH; Tables=
- Run the MCP server:
- Ensure the command line includes the path to the jar and the path to your .prp file, for example: java -jar CDataMCP-jar-with-dependencies.jar /PATH/TO/apache-cassandra.prp
- Note: The server uses stdio and is intended for local use with clients running on the same machine.
- Optionally integrate with Claude Desktop or your MCP client by updating the client config (claude_desktop_config.json) to include the apache_cassandra entry pointing to the java executable, jar, and .prp file path.
Prerequisites recap:
- Java JDK installed
- Maven installed for build
- Access to CData JDBC Driver for Cassandra (license setup per vendor)
- A prepared apache-cassandra.prp connection profile
Additional notes
Tips and notes:
- The MCP server is read-only by design in this implementation; write/update/delete operations are not exposed.
- Ensure the Java process has access to the Cassandra cluster and the JDBC driver jar (DriverPath) at runtime.
- If Claude Desktop does not show the MCP server, fully quit and restart Claude Desktop to reload the config, or verify that the java process is running and the .prp path is correct.
- When configuring the connection, use the provided Connection String utility from the CData driver to test the connection; this helps validate credentials and network access before starting the MCP server.
- The built-in tools use a naming convention: {servername}_get_tables, {servername}_get_columns, {servername}_run_query. In examples, the server is referenced as apache_cassandra, so the corresponding tools would be apache_cassandra_get_tables, etc.
- If you need to test manually, you can exercise the JSON-RPC endpoints for the tools by following the examples in the README to ensure the server responds as expected.