Skip to content

Commit

Permalink
enable recency only for ci target or for recency airflow task
Browse files Browse the repository at this point in the history
update
  • Loading branch information
amishas157 committed Sep 24, 2024
1 parent cd26fd8 commit 45aad24
Show file tree
Hide file tree
Showing 14 changed files with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/fee_stats_agg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: cast(day_agg as timestamp)
interval: 2
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/history_assets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: cast(batch_run_date as timestamp)
interval: 2
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/ledger_current_state/accounts_current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
2 changes: 2 additions & 0 deletions models/marts/ledger_current_state/contract_code_current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@ models:
description: '{{ doc("contract_code_current") }}'
tests:
- dbt_utils.recency:
tags: [recency]
datepart: day
field: closed_at
interval: 7
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 24
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/ledger_current_state/offers_current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/ledger_current_state/trust_lines_current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/ledger_current_state/ttl_current.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: closed_at
interval: 12
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down
1 change: 1 addition & 0 deletions models/marts/trade_agg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ models:
field: cast(day_agg as timestamp)
interval: 2
config:
enabled: (target.name == "ci" or var("is_recency_airflow_task") == "true")
severity: '{{ "error" if target.name == "prod" else "warn" }}'
meta:
description: "Monitors the freshness of your table over time, as the expected time between data updates."
Expand Down

0 comments on commit 45aad24

Please sign in to comment.