-
Notifications
You must be signed in to change notification settings - Fork 0
/
dbt_project.yml
144 lines (131 loc) · 3.39 KB
/
dbt_project.yml
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
# Name your project! Project names should contain only lowercase characters
# and underscores. A good package name should reflect your organization's
# name or the intended use of these models
name: 'dbt_gx_demo'
version: '1.0.0'
config-version: 2
# This setting configures which "profile" dbt uses for this project.
profile: 'dbt_gx_demo'
# These configurations specify where dbt should look for different types of files.
# The `model-paths` config, for example, states that models in this project can be
# found in the "models/" directory. You probably won't need to change these!
model-paths: ["models"]
analysis-paths: ["analyses"]
test-paths: ["tests"]
seed-paths: ["seeds"]
macro-paths: ["macros"]
snapshot-paths: ["snapshots"]
target-path: "target" # directory which will store compiled SQL files
clean-targets: # directories to be removed by `dbt clean`
- "target"
- "dbt_packages"
vars:
load_date: '1992-01-08'
tpch_size: 10 #1, 10, 100, 1000, 10000
'dbt_date:time_zone': 'America/Chicago'
models:
dbt_gx_demo:
# Config indicated by + and applies to all files under models/example/
bronze:
audit:
schema: audit
tags:
- 'audit'
raw_stage:
+materialized: table
raw_vault:
+materialized: table
stage:
+pre-hook: "{{ project_governance_check() }}"
+materialized: view
tags:
- "governance"
flight_demo:
tags:
- 'flight_demo'
sales_demo:
tags:
- 'sales_demo'
- 'stage_sales_demo'
demo_build:
schema: raw
+materialized: table
tags:
- 'demo_build'
processed:
+pre-hook: "{{ project_governance_check() }}"
schema: processed
+materialized: table
tags:
- 'processed'
flight_demo:
tags:
- 'flight_demo'
netflix_demo:
tags:
- 'netflix_demo'
sales_demo:
tags:
- 'sales_demo'
- 'processed_sales_demo'
raw:
schema: raw
+materialized: table
tags:
- 'raw'
flight_demo:
tags:
- 'flight_demo'
netflix_demo:
tags:
- 'netflix_demo'
sales_demo:
tags:
- 'sales_demo'
staging:
+pre-hook: "{{ project_governance_check() }}"
schema: stage
+materialized: table
tags:
- 'staging'
flight_demo:
tags:
- 'flight_demo'
netflix_demo:
tags:
- 'netflix_demo'
sales_demo:
tags:
- 'sales_demo'
- 'staging_sales_demo'
dbt_artifacts:
+materialized: table
+file_format: delta
+database: BRONZE
+schema: DBT
staging:
+database: BRONZE
+schema: DBT
sources:
+materialized: incremental
+on_schema_change: append_new_columns
+full_refresh: false
+database: BRONZE
+schema: RAW
gold:
+materialized: view
silver:
+materialized: view
seeds:
database: BRONZE
schema: RAW
snapshots:
database: BRONZE
schema: STAGE
tests:
project_governance_check:
+database: BRONZE
+schema: DBT
on-run-end:
- "{{ log_dbt_results(results) }}"
- "{{ dbt_artifacts.upload_results(results) }}"