-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is there a plan to support trino metabase model cache? #56
Comments
Hi @ydpzg thanks for the question. Can you elaborate more on your use case, performance and what change you expect with the model cahce? Regards |
Here are the docs for modeling caching: https://www.metabase.com/docs/latest/data-modeling/models.html#model-caching |
Implementation of model caching of postgres driver can be found at: https://github.com/metabase/metabase/blob/master/src/metabase/driver/postgres/ddl.clj I wrote a very primitive implementation of model caching for the starburst driver. Due to my lack of clojure knowledge, most of the code is extracted from the postgres implementation. Since trino does not support all DDL statements in transactions, I removed the transaction wrappers and I haven't added rollbacks so beware. Source Keep in mind that model caching uses
EDIT: Forgot loading the ddl implementation in driver at the time I posted this. Should be fixed now. |
Thanks @Maiquu! |
My use case is : Both are production databases but I need to join data between two in same query for analytics. So if I can store the result of query in database 3 and Metabase always hit that database3 is ideal thing for me. Can this be possible ? |
Currently using Trino on metabase, we have to select one data source as Metabase supports only 2 level hierarchy of databases and tables. If we can allow the capability to use mysql or postgres as the default option in the metabase, then use the model cache that Metabase connectors of those models support, it can solve this issue. That means, on all trino (starburst) connector, select a metadata datasource which will be used internally by metabase to cache model. Then we write the native sql to query other production datasources that are configured in trino itself. |
No description provided.
The text was updated successfully, but these errors were encountered: