Skip to content

Connecting to StarRocks

Prerequisites

  • The StarRocks instance is accessible over the network from the PuppyGraph instance.

Configuration

Configuration Explanation
Username The username of the database
Password The password of the database
JDBC URI A JDBC compatible connection URI of the data source. Since StarRocks is compatible with MySQL 5.x, use the MySQL JDBC URI format: jdbc:mysql://[host]:[port]/[database]. Read this page for more details on how to construct the URI.
JDBC Driver Class

The class name of the JDBC driver.

Since StarRocks is compatible with MySQL 5.x, use the MySQL 5.x driver:

  • com.mysql.jdbc.Driver (MySQL v5.x and earlier - recommended for StarRocks)

You can also use the newer MySQL driver if compatible:

  • com.mysql.cj.jdbc.Driver (MySQL v8.x and later)
JDBC Driver URL

The URL of the MySQL-compatible JDBC Driver.

Use the MySQL 5.x connector that is compatible with StarRocks. For example:

  • https://repo1.maven.org/maven2/mysql/mysql-connector-java/5.1.49/mysql-connector-java-5.1.49.jar

Notes

StarRocks is a modern OLAP database that maintains compatibility with MySQL 5.x protocol. This means you can connect to StarRocks using MySQL JDBC drivers and connection strings. StarRocks provides high-performance analytics capabilities while maintaining MySQL wire protocol compatibility for easy integration.