World's most powerful open data catalog for building a high-performance, geo-distributed and federated metadata lake.
Java ai-catalogdata-catalogdatalakefederated-querylakehousemetadatametalakemodel-catalogopendatacatalogskycomputingstratosphere
[#846] docs(jdbc): add Jdbc catalog document. (#1082)
Clearvivea8dd29cc0942
diff --git a/docs/jdbc-mysql-catalog.md b/docs/jdbc-mysql-catalog.mdnew file mode 100644index 0000000000..bb42f9ef14--- /dev/null+++ b/docs/jdbc-mysql-catalog.md@@ -0,0 +1,109 @@+---+title: "JDBC MySQL catalog"+slug: /jdbc-mysql-catalog+keywords:+- jdbc+- MySQL+- metadata+license: "Copyright 2023 Datastrato Pvt Ltd.+This software is licensed under the Apache License version 2."+---++## Introduction+Gravitino provides the ability to manage MySQL metadata.++## Catalog+### Catalog capabilities+- Supports metadata management of MySQL(5.6, 5.7, 8.0).+- Supports DDL operation for MySQL databases and tables.+- Doesn't support table index operations.+- Doesn't support setting certain column properties, such as default value and check constraints.++### Catalog properties+Any property that isn't defined by Gravitino can pass to MySQL data source by adding `gravitino.bypass` prefix as a catalog property. For example, catalog property `gravitino.bypass.maxWaitMillis` will pass `maxWaitMillis` to the data source property.+You can check the relevant data source configuration in [data source properties](https://commons.apache.org/proper/commons-dbcp/configuration.html)++If you use JDBC catalog, you must provide `jdbc-url`, `jdbc-driver`, `jdbc-user` and `jdbc-password` to catalog properties.++| Configuration item | Description | Default value | Required | Since Version |+|-------------------------|------------------------------------------------------------------------------------------------------------|---------------|----------|---------------|+| `jdbc-url` | JDBC URL for connecting to the database. For example `jdbc:mysql://localhost:3306` | (none) | Yes | 0.3.0 |+| `jdbc-driver` | The driver of the jdbc connection. For example `com.mysql.jdbc.Driver` or `com.mysql.cj.jdbc.Driver`. | (none) | Yes | 0.3.0 |+| `jdbc-user` | The JDBC user name. | (none) | Yes | 0.3.0 |+| `jdbc-password` | The JDBC password. | (none) | Yes | 0.3.0 |+| `jdbc.pool.min-size` | The minimum number of connections in the pool. `2` by default. | `2` | No | 0.3.0 |+| `jdbc.pool.max-size` | The maximum number of connections in the pool. `10` by default. | `10` | No | 0.3.0 |++:::caution+You must download the corresponding JDBC driver to the `catalogs/jdbc-mysql/libs` directory.+:::++### Catalog operations+see [Manage metadata using Gravitino](./manage-metadata-using-gravitino#catalogs-operations).++## Schema+### Schema capabilities+- Gravitino schema corresponds to the MySQL database.+- Support create schema with comments.+- Support drop schema.+- Doesn't support cascade drop database.++### Schema properties+- Doesn't support are database property settings.++### Schema operations+see [Manage metadata using Gravitino](./manage-metadata-using-gravitino#schemas-operations).++## Table+### Table capabilities+- Gravitino table corresponds to the MySQL table.+- Supports DDL operation for MySQL tables.+- Doesn't support setting certain column properties, such as default value and check constraints.+- Doesn't support index definition.+- Doesn't support table property settings.++#### Table column types+| Gravitino Type | Mysql Type |+|------------------|-------------|+| `Byte` | `Tinyint` |+| `Short` | `Smallint` |+| `Integer` | `Int` |+| `Long` | `Bigint` |+| `Float` | `Float` |+| `Double` | `Double` |+| `String` | `Text` |+| `Date` | `Date` |+| `Time` | `Time` |+| `Timestamp` | `Timestamp` |+| `Decimal` | `Decimal` |+| `VarChar` | `VarChar` |+| `FixedChar` | `FixedChar` |+| `Binary` | `Binary` |++:::info+MySQL doesn't support Gravitino `Boolean` `Fixed` `Struct` `List` `Map` `Timestamp_tz` `IntervalDay` `IntervalYear` `Union` `UUID` type.+:::++### Table properties+- Doesn't support table properties.++### Table operations+#### Alter table operations+Supports operations:+- `RenameTable`+- `UpdateComment`+- `AddColumn`+- `DeleteColumn`+- `RenameColumn`+- `UpdateColumnType`+- `UpdateColumnPosition`+- `UpdateColumnNullability`+- `UpdateColumnComment`++:::info+The `RenameTable` operation cannot be submitted at the same time as other operations+:::++:::caution+If you update a nullability column to non nullability, there may be compatibility issue.+:::\ No newline at end of filediff --git a/docs/jdbc-postgresql-catalog.md b/docs/jdbc-postgresql-catalog.mdnew file mode 100644index 0000000000..195440e909--- /dev/null+++ b/docs/jdbc-postgresql-catalog.md@@ -0,0 +1,117 @@+---+title: "JDBC PostgreSQL catalog"+slug: /jdbc-postgresql-catalog+keywords:+- jdbc+- PostgreSQL+- metadata+license: "Copyright 2023 Datastrato Pvt Ltd.+This software is licensed under the Apache License version 2."+---++## Introduction+Gravitino provides the ability to manage PostgreSQL metadata.++## Catalog+### Catalog capabilities+- Gravitino catalog corresponds to the PostgreSQL database.+- Supports metadata management of PostgreSQL(9.2, 12.0, 13.0).+- Supports DDL operation for PostgreSQL schemas and tables.+- Doesn't support table index operations.+- Doesn't support setting certain column properties, such as default value and check constraints++### Catalog properties+Any property that isn't defined by Gravitino can pass to MySQL data source by adding `gravitino.bypass` prefix as a catalog property. For example, catalog property `gravitino.bypass.maxWaitMillis` will pass `maxWaitMillis` to the data source property.+You can check the relevant data source configuration in [data source properties](https://commons.apache.org/proper/commons-dbcp/configuration.html)++If you use JDBC catalog, you must provide `jdbc-url`, `jdbc-driver`, `jdbc-database`, `jdbc-user` and `jdbc-password` to catalog properties.++| Configuration item | Description | Default value | Required | Since Version |+|----------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------|----------|---------------|+| `jdbc-url` | JDBC URL for connecting to the database. You need to specify the database in the URL. For example `jdbc:postgresql://localhost:3306/pg_database?sslmode=require`. | (none) | Yes | 0.3.0 |+| `jdbc-driver` | The driver of the jdbc connection. For example `org.postgresql.Driver`. | (none) | Yes | 0.3.0 |+| `jdbc-database` | The database of the JDBC connection. Needs to be configured with the same value as database in `jdbc-url`. For example `pg_database`. | (none) | Yes | 0.3.0 |+| `jdbc-user` | The JDBC user name. | (none) | Yes | 0.3.0 |+| `jdbc-password` | The JDBC password. | (none) | Yes | 0.3.0 |+| `jdbc.pool.min-size` | The minimum number of connections in the pool. `2` by default. | `2` | No | 0.3.0 |+| `jdbc.pool.max-size` | The maximum number of connections in the pool. `10` by default. | `10` | No | 0.3.0 |++:::caution+You must download the corresponding JDBC driver to the `catalogs/jdbc-postgresql/libs` directory.+You must explicitly specify the database in both `jdbc-url` and `jdbc-database`. The values in both must be consistent; otherwise, an error will occur.+:::+:::info+In PostgreSQL, the database corresponds to the Gravitino catalog, and the schema corresponds to the Gravitino schema.+:::++### Catalog operations+see [Manage metadata using Gravitino](./manage-metadata-using-gravitino#catalogs-operations).++## Schema+### Schema capabilities+- Gravitino schema corresponds to the PostgreSQL schema.+- Support create schema with comments.+- Support drop schema.+- Support cascade drop schema.++### Schema properties+- Doesn't are schema property settings.++### Schema operations+see [Manage metadata using Gravitino](./manage-metadata-using-gravitino#schemas-operations).++## Table+### Table capabilities+- Gravitino table corresponds to the PostgreSQL table.+- Supports DDL operation for PostgreSQL tables.+- Doesn't support setting certain column properties, such as default value and check constraints.+- Doesn't support index definition.+- Doesn't support table property settings.++#### Table column types+| Gravitino Type | PostgreSQL Type |+|----------------|-------------------------------|+| `Boolean` | `boolean` |+| `Byte` | `Tinyint` |+| `Short` | `Smallint` |+| `Integer` | `Integer` |+| `Long` | `Bigint` |+| `Float` | `Real` |+| `Double` | `Double precision` |+| `String` | `Text` |+| `Date` | `Date` |+| `Time` | `Time without time zone` |+| `Timestamp` | `Timestamp without time zone` |+| `Timestamp_tz` | `Timestamp with time zone` |+| `Decimal` | `Numeric` |+| `VarChar` | `Character varying` |+| `FixedChar` | `FixedChar` |+| `Binary` | `Bytea` |++:::info+PostgreSQL doesn't support Gravitino `Fixed` `Struct` `List` `Map` `IntervalDay` `IntervalYear` `Union` `UUID` type.+:::++### Table properties+- Doesn't support table properties.++### Table operations+#### Alter table operations+Supports operations:+- `RenameTable`+- `UpdateComment`+- `AddColumn`+- `DeleteColumn`+- `RenameColumn`+- `UpdateColumnType`+- `UpdateColumnNullability`+- `UpdateColumnComment`++:::info+The `RenameTable` operation cannot be submitted at the same time as other operations+:::++:::caution+PostgreSQL does not support the `UpdateColumnPosition` operation, so you can only use `ColumnPosition.defaultPosition()` when `AddColumn`.+If you update a nullability column to non nullability, there may be compatibility issue.+:::\ No newline at end of file