gouline / dbt-metabase

dbt + Metabase integration
https://pypi.org/project/dbt-metabase/
MIT License
462 stars 71 forks source link

Exposure Parsing #28

Closed z3z1ma closed 3 years ago

z3z1ma commented 3 years ago

Description

Parsing exposures from Metabase automatically in relation to a dbt project. This function is huge for understanding exposures within your data model. Close the loop between model composition and tangible BI exposures of those models creating an extremely valuable company asset in the dbt docs. In the nature of this project, the aim is we can use almost the same invocation parameters users set up in CI / CD for dbt-metabase export as they can with dbt-metabase exposures. This lets you run the invocation in production to essentially keep you docs in full sync with BI.

Note: Just opening this for visibility and preliminary code introspection. A bit more to do (but not too much).

Type of change

How Has This Been Tested?

Open to ideas but ultimately I think making a mock api from metabase running on top of a database that has been seeded and ran through with the dbt jaffle shop project would be most robust. Just a lot of work.

Test Configuration:

Checklist:

References #22

z3z1ma commented 3 years ago

Working on documentation updates now Then will move onto some pretty cool unit tests

Code is in a reviewable state as is though

z3z1ma commented 3 years ago

image

image

Example native query parsed from Metabase into exposure with verbose documentation auto-generated into revisionable YAML.

image

Example DAG of exposures on a single focused node.