-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathhalf-config.yaml
58 lines (53 loc) · 1.37 KB
/
half-config.yaml
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
app_name: local-application
connections:
- config: !LocalStorage
details:
path: 2-active-data
tables:
- !Table
name: customers
config: !Parquet
path: customers
extension: .parquet
- !Table
name: orders
config: !Parquet
path: orders
extension: .parquet
- !Table
name: order_items
config: !Parquet
path: order_items
extension: .parquet
- !Table
name: products
config: !Parquet
path: products
extension: .parquet
name: delta
sql: |
select c.customer_id, c.name, c.email, o.order_id, o.order_date, o.total_amount, COUNT(*)
into customer_orders
from customers c
inner join orders o on c.customer_id = o.customer_id
join order_items i on o.order_id = i.order_id
join products p on i.product_id = p.product_id
group by c.customer_id, c.name, c.email, o.order_id, o.order_date, o.total_amount
endpoints:
- name: customers
path: /customers
table_name: customers
index:
primary_key:
- customer_id
- name: orders
path: /orders
table_name: orders
index:
primary_key:
- order_id
- name: customer_orders_cache
path: /customer_orders
table_name: customer_orders
telemetry:
metrics: !Prometheus