FANNG1 commented on code in PR #9689: URL: https://github.com/apache/gravitino/pull/9689#discussion_r2752436489
########## docs/flink-connector/flink-catalog-hive.md: ########## @@ -23,14 +23,32 @@ Supports most DDL and DML operations in Flink SQL, except such operations: - `DELETE` clause - `CALL` clause +## Generic table support + +Flink generic tables are non-Hive tables. Their schema and partition keys are stored in table +properties in Hive metastore. Gravitino Flink connector follows the Flink Hive catalog behavior: + +- If `connector=hive`, the table is treated as a Hive table and stored with a normal Hive schema. +- If the connector is missing or not `hive`, the table is treated as a generic table. Gravitino + stores an empty Hive schema and serializes schema and partition keys into `flink.*` properties. + It also uses the `is_generic` flag when needed for compatibility. + +When loading or altering a table, Gravitino Flink connector detects generic tables by the +`is_generic`, `flink.connector`, and `flink.connector.type` properties. Generic tables are +reconstructed from the serialized `flink.*` properties. Hive tables continue to use the native +Hive schema. + +:::note +You must set `connector=hive` explicitly when creating a raw Hive table. Otherwise, the table is created as a managed generic table. The managed table is not recommended to use and is deprecated in Flink. Review Comment: update the document, and managed table related API is deprecated in Flink 1.18 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
