trino icon indicating copy to clipboard operation
trino copied to clipboard

Add support of JDBC store for the dynamic catalog feature

Open cdrappier opened this issue 1 year ago • 15 comments

Description

Based on the new dynamic catalog, compatible with file and memory. I've try to add a compatibility with a jdbc database for store them. The main feature of dynamic catalog come from this Issue : https://github.com/trinodb/trino/issues/12709#issuecomment-1290290147

Additional context and related issues

Goal is to avoid the need of a persistant volume with a persistent dynamic catalog.

Release notes

( ) This is not user-visible or docs only and no release notes are required. ( ) Release notes are required, please propose a release note for me. (x) Release notes are required, with the following suggested text:

# DynamicCatalog
* Add support for storing the dynamic catalog through a jdbc connector

cdrappier avatar Mar 23 '23 17:03 cdrappier

Due to problem of duplicate classes I've had some exclusion inside other plugin. I'm not sure it's the right way to deal with that problem

cdrappier avatar Apr 05 '23 10:04 cdrappier

This pull request has gone a while without any activity. Tagging the Trino developer relations team: @bitsondatadev @colebow @mosabua

github-actions[bot] avatar Apr 26 '23 20:04 github-actions[bot]

@dain can you look and chime in to see if this approach is in line with the planned features?

mosabua avatar Apr 26 '23 23:04 mosabua

@trinodb/devrel could one of you find someone to give this PR a look while @dain is out? Just to verify best practices are being followed.

bitsondatadev avatar May 09 '23 10:05 bitsondatadev

On my side, we are actively using it in production right now, will be happy to go further on it.

cdrappier avatar Aug 14 '23 13:08 cdrappier

On my side, we are actively using it in production right now, will be happy to go further on it.

@cdrappier Hi, thanks for your work. But have you encountered the situation like these issues while using dynamic catalogs? https://github.com/trinodb/trino/issues/18040 Unknown handle id: hive:hive:XXX:io.trino.plugin.hive.HiveTableHandle when using dynamic catalogs https://github.com/trinodb/trino/issues/18053 Dynamic Catalogs - Sync Catalog Properties to Worker Node

gnehc-hc avatar Dec 19 '23 06:12 gnehc-hc

Can you rebase this PR @cdrappier

@dain you mentioned that this feature might be a good add ... can you help with providing guidance with the PR?

mosabua avatar Dec 20 '23 06:12 mosabua

This pull request has gone a while without any activity. Tagging the Trino developer relations team: @bitsondatadev @colebow @mosabua

github-actions[bot] avatar Jan 17 '24 17:01 github-actions[bot]

@cdrappier could you potentially rebase so we can verify it against CI and then we can try to get reviewers involved again to get this to merge.

mosabua avatar Jan 17 '24 18:01 mosabua

This pull request has gone a while without any activity. Tagging the Trino developer relations team: @bitsondatadev @colebow @mosabua

github-actions[bot] avatar Feb 12 '24 17:02 github-actions[bot]

Closing this pull request, as it has been stale for six weeks. Feel free to re-open at any time.

github-actions[bot] avatar Mar 05 '24 17:03 github-actions[bot]

I am reopening because I think @dain mentioned that he would like to have a look.

mosabua avatar Mar 05 '24 19:03 mosabua

This pull request has gone a while without any activity. Tagging the Trino developer relations team: @bitsondatadev @colebow @mosabua

github-actions[bot] avatar Mar 28 '24 17:03 github-actions[bot]

@cdrappier is it possible to sync the catalogs periodically? as there might be more than 1 clusters, the catalog created on one cluster might also be used on another cluster.

jerryleooo avatar Apr 30 '24 03:04 jerryleooo

@jerryleooo there is no multi-cluster support in Trino as such at this stage. Therefore this feature should also not take this idea into account.

At least not in the initial implementation .. later down the track this could make sense in Trino itself.. or in orchestration from some other system, including potentially Trino Gateway

mosabua avatar Apr 30 '24 15:04 mosabua

Fyi @dprophet .. you could use this as a base to expand and improve and work with @dain and @cdrappier

mosabua avatar May 03 '24 18:05 mosabua

This pull request has gone a while without any activity. Tagging the Trino developer relations team: @bitsondatadev @colebow @mosabua

github-actions[bot] avatar May 27 '24 17:05 github-actions[bot]

At this point, I think this PR is abandoned. Trino now has an official SPI interface for catalog storage and a new implementation should be created using that interface.

dain avatar Jun 26 '24 18:06 dain