Skip to main content

Iceberg JDBC Catalog

Before creating a catalog or running a load or export job, ensure that the warehouse can reach the service endpoint and that its credentials have the required metadata and data permissions. For private endpoints or service-side credential files, coordinate connectivity and provisioning with VeloDB Cloud support.

This document describes the supported parameters when connecting to and accessing Iceberg Catalog metadata services using the JDBC interface through the CREATE CATALOG statement.

Tip:

This experimental feature is available from VeloDB Core 26.1.1. Coordinate JDBC driver requirements with VeloDB Cloud support before use.

Parameters​

Property NameDescriptionDefault ValueRequired
iceberg.jdbc.uriSpecifies the JDBC connection URI-Yes
iceberg.jdbc.catalog_nameSpecifies the catalog_name isolation key in Iceberg JDBC metadata tables. This value can be different from the VeloDB Cloud catalog name.-Yes
iceberg.jdbc.userJDBC connection username-No
iceberg.jdbc.passwordJDBC connection password-No
warehouseSpecifies the iceberg warehouse-Yes
iceberg.jdbc.init-catalog-tablesWhether to automatically initialize Catalog-related table structures on first usetrueNo
iceberg.jdbc.schema-versionSchema version used by JDBC Catalog, supports V0 and V1V0No
iceberg.jdbc.strict-modeWhether to enable strict mode, which performs stricter validation of metadatafalseNo
iceberg.jdbc.driver_classJDBC driver class name, such as org.postgresql.Driver, com.mysql.cj.jdbc.Driver, etc.-No
iceberg.jdbc.driver_urlPath to JDBC driver JAR file-No

Note:

  1. Iceberg JDBC Catalog supports various relational databases as backend storage, including PostgreSQL, MySQL, SQLite, etc.

  2. Ask VeloDB Cloud support to approve and provision the JDBC driver. If instructed to use a reachable HTTPS driver URL, specify it via iceberg.jdbc.driver_url.

  3. iceberg.jdbc.catalog_name must match the Iceberg JDBC catalog name used by the writer, such as spark_catalog for metadata written by Spark.

  4. If iceberg.jdbc.driver_url is specified, iceberg.jdbc.driver_class must also be specified.

Example configurations​

Use PostgreSQL for metadata​

View use postgresql for metadata

Using PostgreSQL database to store Iceberg metadata:

CREATE CATALOG iceberg_jdbc_postgresql PROPERTIES (
'type' = 'iceberg',
'iceberg.catalog.type' = 'jdbc',
'iceberg.jdbc.catalog_name' = 'iceberg_jdbc_postgresql',
'iceberg.jdbc.uri' = 'jdbc:postgresql://<postgresql-host>:5432/iceberg_db',
'iceberg.jdbc.user' = 'iceberg_user',
'iceberg.jdbc.password' = '<database-password>',
'iceberg.jdbc.init-catalog-tables' = 'true',
'iceberg.jdbc.schema-version' = 'V1',
'iceberg.jdbc.driver_class' = 'org.postgresql.Driver',
'iceberg.jdbc.driver_url' = '<https-jdbc-driver-url>',
'warehouse' = 's3://bucket/warehouse',
's3.access_key' = '<ak>',
's3.secret_key' = '<sk>',
's3.endpoint' = 'https://s3.us-east-1.amazonaws.com',
's3.region' = 'us-east-1'
);

Use MySQL for metadata​

View use mysql for metadata

Using MySQL database to store Iceberg metadata:

CREATE CATALOG iceberg_jdbc_mysql PROPERTIES (
'type' = 'iceberg',
'iceberg.catalog.type' = 'jdbc',
'iceberg.jdbc.catalog_name' = 'iceberg_jdbc_mysql',
'iceberg.jdbc.uri' = 'jdbc:mysql://<mysql-host>:3306/iceberg_db',
'iceberg.jdbc.user' = 'iceberg_user',
'iceberg.jdbc.password' = '<database-password>',
'iceberg.jdbc.init-catalog-tables' = 'true',
'iceberg.jdbc.schema-version' = 'V1',
'iceberg.jdbc.driver_class' = 'com.mysql.cj.jdbc.Driver',
'iceberg.jdbc.driver_url' = '<https-jdbc-driver-url>',
'warehouse' = 's3://bucket/warehouse',
's3.access_key' = '<ak>',
's3.secret_key' = '<sk>',
's3.endpoint' = 'https://s3.us-east-1.amazonaws.com',
's3.region' = 'us-east-1'
);

SQLite metadata storage​

View sqlite metadata storage

The following is an upstream SQLite compatibility example. Its local database file is opened by the service process and is unsuitable as a shared metastore across warehouse nodes. Use PostgreSQL or MySQL for a network-accessible metastore; do not copy this local-file configuration into a warehouse catalog.

CREATE CATALOG iceberg_jdbc_sqlite PROPERTIES (
'type' = 'iceberg',
'iceberg.catalog.type' = 'jdbc',
'iceberg.jdbc.catalog_name' = 'iceberg_jdbc_sqlite',
'iceberg.jdbc.uri' = 'jdbc:sqlite:/tmp/iceberg_catalog.db',
'iceberg.jdbc.init-catalog-tables' = 'true',
'iceberg.jdbc.schema-version' = 'V1',
'iceberg.jdbc.driver_class' = 'org.sqlite.JDBC',
'iceberg.jdbc.driver_url' = '<https-jdbc-driver-url>',
'warehouse' = 's3://bucket/warehouse',
's3.access_key' = '<ak>',
's3.secret_key' = '<sk>',
's3.endpoint' = 'https://s3.us-east-1.amazonaws.com',
's3.region' = 'us-east-1'
);

Common errors​

For access-denied errors, check the identity and its permissions for both metadata and data. For timeouts, verify the service endpoint and network path from the warehouse. For errors involving a keytab, CA certificate, Hadoop XML file, or JDBC driver, contact VeloDB Cloud support with the error text and the operation that failed.