File size: 6,514 Bytes
0510038 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
{
"warehouse": {
"platform": "Snowflake",
"account": "xy12345.us-east-1",
"database": "ANALYTICS_DW"
},
"lineage": {
"datasets": [
{
"id": "raw.customers",
"type": "table",
"database": "ANALYTICS_DW",
"schema": "RAW",
"name": "CUSTOMERS",
"description": "Raw customer data from CRM",
"columns": [
{"name": "CUSTOMER_ID", "type": "NUMBER", "isPrimaryKey": true},
{"name": "EMAIL", "type": "VARCHAR", "pii": true},
{"name": "NAME", "type": "VARCHAR"},
{"name": "CREATED_AT", "type": "TIMESTAMP_NTZ"},
{"name": "SOURCE_SYSTEM", "type": "VARCHAR"}
],
"tags": ["pii", "raw"],
"owner": "data-platform-team"
},
{
"id": "raw.transactions",
"type": "table",
"database": "ANALYTICS_DW",
"schema": "RAW",
"name": "TRANSACTIONS",
"description": "Raw transaction events from payment gateway",
"columns": [
{"name": "TRANSACTION_ID", "type": "VARCHAR", "isPrimaryKey": true},
{"name": "CUSTOMER_ID", "type": "NUMBER", "isForeignKey": true, "references": "raw.customers.CUSTOMER_ID"},
{"name": "AMOUNT", "type": "NUMBER"},
{"name": "CURRENCY", "type": "VARCHAR"},
{"name": "TRANSACTION_DATE", "type": "DATE"},
{"name": "STATUS", "type": "VARCHAR"}
],
"tags": ["financial", "raw"],
"owner": "data-platform-team"
},
{
"id": "raw.products",
"type": "table",
"database": "ANALYTICS_DW",
"schema": "RAW",
"name": "PRODUCTS",
"description": "Product catalog from inventory system"
},
{
"id": "staging.customers_cleaned",
"type": "view",
"database": "ANALYTICS_DW",
"schema": "STAGING",
"name": "CUSTOMERS_CLEANED",
"description": "Deduplicated and cleaned customer records",
"transformation": "DEDUP + CLEAN + VALIDATE",
"owner": "analytics-engineering"
},
{
"id": "staging.transactions_enriched",
"type": "view",
"database": "ANALYTICS_DW",
"schema": "STAGING",
"name": "TRANSACTIONS_ENRICHED",
"description": "Transactions with currency conversion and status mapping",
"transformation": "ENRICH + CONVERT + MAP"
},
{
"id": "marts.dim_customer",
"type": "table",
"database": "ANALYTICS_DW",
"schema": "MARTS",
"name": "DIM_CUSTOMER",
"description": "Customer dimension with SCD Type 2",
"transformation": "SCD_TYPE_2 + AGGREGATE"
},
{
"id": "marts.fct_transaction",
"type": "table",
"database": "ANALYTICS_DW",
"schema": "MARTS",
"name": "FCT_TRANSACTION",
"description": "Transaction fact table with dimensions"
},
{
"id": "reporting.customer_360",
"type": "view",
"database": "ANALYTICS_DW",
"schema": "REPORTING",
"name": "CUSTOMER_360",
"description": "Complete customer view for BI tools"
},
{
"id": "reporting.revenue_dashboard",
"type": "materialized_view",
"database": "ANALYTICS_DW",
"schema": "REPORTING",
"name": "REVENUE_DASHBOARD",
"description": "Aggregated revenue metrics for executive dashboard",
"refresh_schedule": "DAILY at 06:00 UTC"
},
{
"id": "external.crm_export",
"type": "external_table",
"location": "s3://company-exports/crm/",
"description": "CRM data export to S3"
},
{
"id": "external.bi_semantic_layer",
"type": "semantic_model",
"platform": "Looker",
"description": "Looker semantic model for self-service analytics"
}
],
"relationships": [
{
"source": "raw.customers",
"target": "staging.customers_cleaned",
"type": "transform",
"job": "dbt_staging_customers",
"schedule": "hourly"
},
{
"source": "raw.transactions",
"target": "staging.transactions_enriched",
"type": "transform",
"job": "dbt_staging_transactions"
},
{
"source": "staging.customers_cleaned",
"target": "marts.dim_customer",
"type": "transform",
"job": "dbt_marts_dim_customer"
},
{
"source": "staging.transactions_enriched",
"target": "marts.fct_transaction",
"type": "transform"
},
{
"source": "raw.products",
"target": "marts.fct_transaction",
"type": "reference"
},
{
"source": "marts.dim_customer",
"target": "marts.fct_transaction",
"type": "reference"
},
{
"source": "marts.dim_customer",
"target": "reporting.customer_360",
"type": "transform"
},
{
"source": "marts.fct_transaction",
"target": "reporting.customer_360",
"type": "transform"
},
{
"source": "marts.fct_transaction",
"target": "reporting.revenue_dashboard",
"type": "aggregate"
},
{
"source": "marts.dim_customer",
"target": "reporting.revenue_dashboard",
"type": "reference"
},
{
"source": "reporting.customer_360",
"target": "external.crm_export",
"type": "export",
"job": "airflow_crm_sync"
},
{
"source": "reporting.revenue_dashboard",
"target": "external.bi_semantic_layer",
"type": "publish",
"job": "looker_sync"
}
],
"jobs": [
{
"id": "dbt_staging_customers",
"type": "dbt",
"schedule": "0 * * * *",
"description": "Hourly customer staging refresh"
},
{
"id": "dbt_staging_transactions",
"type": "dbt",
"schedule": "0 * * * *"
},
{
"id": "dbt_marts_dim_customer",
"type": "dbt",
"schedule": "0 2 * * *"
},
{
"id": "airflow_crm_sync",
"type": "airflow",
"schedule": "0 6 * * *"
},
{
"id": "looker_sync",
"type": "api",
"schedule": "0 7 * * *"
}
]
},
"notes": "Sample Snowflake data warehouse lineage with multi-layer architecture (raw, staging, marts, reporting) and external system integrations."
}
|