Entity Caching
Entities may have calculated attributes that are expensive to compute - with aggregations, JOINs or large table scans. By default, every access to a calculated attribute recomputes it. However, for most calculated attributes recomputation is not necessary. Entity cache enables materializing entities, in order to avoid re-computation. The cache is updated upon triggers or according to a set schedule. The cache is stored as tables in your Snowflake, and is recomputed based on configuration. When entity cache is enabled, Honeydew will automatically leverage data in the cache when applicable.Entity caches are singlular and are shared across domains and branches.
Configuration
Set up in Entity YAML schema cache delivery settings for Snowflake:Configuration when using dbt as orchestrator
Set up in Entity YAML schema cache delivery settings for dbt:Orchestration
Entity Cache refresh relies on external orchestration
(with dbt, Apache Airflow, or otherwise) or manual deployments.
Set up with Honeydew
Use the Honeydew deploy functionality to write the entity cache to a table from the UI. For Snowflake, you can also use the Native Application Deploy API:Set up with ETL tools
For Snowflake, use the Native Application API to get SQL for the entity cache:Set up with dbt
To set up dbt as a cache orchestrator:- In dbt, create an entity cache model by using the Honeydew dbt cache macro
- In dbt, use the
configmacro to set up materialization settings such as clustering or dynamic tables - In Honeydew, set the entity’s dbt delivery settings to the chosen dbt model name
customers model in dbt: