From 4cfb3aaf32f6902edd710eaa2bb05d10e32d057e Mon Sep 17 00:00:00 2001 From: izzy Date: Tue, 12 Dec 2023 15:19:35 -0700 Subject: [PATCH] updated sling asset name --- dbt_project/models/CLEANED/locations_cleaned.sql | 2 +- dbt_project/models/sources.yml | 5 +---- hooli-demo-assets/hooli_demo_assets/assets/sling.py | 4 ++-- hooli-demo-assets/hooli_demo_assets/jobs/__init__.py | 2 +- 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/dbt_project/models/CLEANED/locations_cleaned.sql b/dbt_project/models/CLEANED/locations_cleaned.sql index 7f3ff4b6..78c7c72a 100644 --- a/dbt_project/models/CLEANED/locations_cleaned.sql +++ b/dbt_project/models/CLEANED/locations_cleaned.sql @@ -1,7 +1,7 @@ with source as ( select * -from {{ source("RAW_DATA", "location") }} +from {{ source("RAW_DATA", "locations") }} ), diff --git a/dbt_project/models/sources.yml b/dbt_project/models/sources.yml index afeb4c76..0a8fb804 100644 --- a/dbt_project/models/sources.yml +++ b/dbt_project/models/sources.yml @@ -5,10 +5,7 @@ sources: tables: - name: "orders" - name: "users" - - name: "location" - meta: - dagster: - asset_key: ['location'] + - name: "locations" - name: "FORECASTING" tables: - name: "predicted_orders" diff --git a/hooli-demo-assets/hooli_demo_assets/assets/sling.py b/hooli-demo-assets/hooli_demo_assets/assets/sling.py index 4bc32ec0..ca7ebbff 100644 --- a/hooli-demo-assets/hooli_demo_assets/assets/sling.py +++ b/hooli-demo-assets/hooli_demo_assets/assets/sling.py @@ -3,9 +3,9 @@ raw_location = build_sling_asset( - asset_spec=AssetSpec(key=["location"]), + asset_spec=AssetSpec(key=["locations"]), source_stream="s3://hooli-demo/embedded-elt/", - target_object= "RAW_DATA.LOCATION", + target_object= "RAW_DATA.LOCATIONS", mode=SlingMode.FULL_REFRESH, source_options={"format": "csv"}, sling_resource_key="s3_to_snowflake_resource" diff --git a/hooli-demo-assets/hooli_demo_assets/jobs/__init__.py b/hooli-demo-assets/hooli_demo_assets/jobs/__init__.py index caee6048..127905b0 100644 --- a/hooli-demo-assets/hooli_demo_assets/jobs/__init__.py +++ b/hooli-demo-assets/hooli_demo_assets/jobs/__init__.py @@ -1,6 +1,6 @@ from dagster import AssetSelection, define_asset_job -raw_location_by_day = AssetSelection.keys(["RAW_DATA", "location"]) +raw_location_by_day = AssetSelection.keys(["RAW_DATA", "locations"]) daily_sling_job = define_asset_job( name="daily_sling_job",