jlalwani-amazon opened a new pull request, #36:
URL: https://github.com/apache/flink-connector-hive/pull/36

   ---
   
   ## What is the purpose of the change
   
   Adapt the external Hive connector to compile against Flink 2.0.0 by 
removing/migrating deprecated APIs that were removed in the 2.0 release.
   
   This is a **draft PR** - work in progress. Opening early for visibility and 
feedback.
   
   *JIRA: [FLINK-37094](https://issues.apache.org/jira/browse/FLINK-37094)*
   
   ## Brief change log
   
   **Completed:**
   - Bump `flink.version` from 1.20.0 to 2.0.0
   - Rename `flink-hadoop-compatibility_2.12` to `flink-hadoop-compatibility` 
(Scala suffix dropped in Flink 2.0)
   - Remove `flink-java` test dependency (DataSet API removed in Flink 2.0)
   - Delete `HiveTableFactory.java` (legacy 
`TableSourceFactory`/`TableSinkFactory` removed)
   - Remove `HiveCatalog.getTableFactory()` (legacy catalog method)
   - Remove `ManagedTableFactory` reference from `HiveCatalog`
   - Migrate `FileSystemLookupFunction` from `TableFunction<RowData>` to 
`LookupFunction`
   - Update `HiveLookupTableSource` to use `LookupFunctionProvider` instead of 
legacy `TableFunctionProvider`
   - Remove `testGenericTable` test that tested deleted `HiveTableFactory`
   
   **Remaining (WIP):**
   - [ ] Replace `UniqueConstraint` with Flink 2.0 equivalent (7 files 
including HiveShim interface)
   - [ ] Replace `StreamingFileSink`/`BucketsBuilder` with `FileSink` API in 
`HiveTableSink`
   - [ ] Handle `CatalogLock`/`RequireCatalogLock` removal
   - [ ] Handle `ManagedTableFactory`/`ManagedTableListener` removal in 
remaining files
   
   ## Verifying this change
   
   - Compilation against Flink 2.0.0 (currently 72 errors remaining, down from 
100)
   - Existing tests pass (test compilation succeeds, 0 test errors)
   
   ## Does this pull request potentially affect one of the following parts
   
   - Dependencies: yes (Flink version bump, removed flink-java)
   - The public API: yes (removed legacy TableSourceFactory/TableSinkFactory 
support)
   - Connector API: yes (migrated from TableFunctionProvider to 
LookupFunctionProvider)
   
   ## Notes for reviewers
   
   1. This PR targets Flink 2.x only and is **not backward compatible with 
Flink 1.x**. Should this go on `main` or a separate branch (e.g., `v2.0`)?
   2. The `HiveTableFactory` deletion removes the legacy path for generic 
(non-Hive) tables in HiveCatalog. The modern `HiveDynamicTableFactory` path via 
`Catalog.getFactory()` is unaffected.
   3. Hive 2.3/3.1 compatibility is preserved - all changes are in the 
Flink-facing layer, not the Hive-facing layer.
   4. Related mailing list discussion: `[DISCUSS] Adding Apache Hive 4.x 
support to flink-connector-hive`
   
   
   **Question for maintainers:** This PR targets Flink 2.x and is not backward 
compatible with 1.x. Should I retarget this to a new `v2.0` branch instead of 
`main`? Happy to rebase once the branch is created. 


-- 
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]

Reply via email to