forked from SocialFinanceDigitalLabs/liia-tools
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
349 additions
and
277 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
from dagster import job | ||
|
||
from decouple import config as env_config | ||
from liiatools_pipeline.ops import external_dataset as ed | ||
|
||
from liiatools_pipeline.assets import external_dataset as ed_assets | ||
|
||
@job | ||
def external_incoming(): | ||
ed.request_dataset() | ||
ed.request_dataset(ed_assets.ons_data_location()) | ||
ed.request_dataset(ed_assets.ofsted_data_location()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
from sufficiency_data_transform.all_dim_and_fact import create_sufficiency_data | ||
from dagster import job | ||
from liiatools_pipeline.ops import ssda903 | ||
|
||
|
||
@job | ||
def ssda903_sufficiency(): | ||
print("Hi") | ||
create_sufficiency_data() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
from dagster import RunRequest, run_status_sensor, sensor, DagsterRunStatus, RunConfig, DefaultSensorStatus | ||
|
||
from liiatools_pipeline.jobs.ssda903 import ssda903_incoming | ||
from liiatools_pipeline.jobs.sufficiency_903 import ssda903_sufficiency | ||
|
||
''' | ||
@run_status_sensor( | ||
run_status=DagsterRunStatus.SUCCESS, | ||
description="Adds in ONS and census data once 903 pipeline completes", | ||
request_job=ssda903_incoming, | ||
) | ||
@sensor( | ||
job=ssda903_sufficiency, | ||
minimum_interval_seconds=300, | ||
default_status=DefaultSensorStatus.RUNNING, | ||
) | ||
def sufficiency_sensor(context): | ||
yield RunRequest( | ||
run_key=None, | ||
run_config=RunConfig(), | ||
)''' |
Oops, something went wrong.