Created
August 27, 2020 20:44
-
-
Save anna-anisienia/f98df4b86c810d2d3354e90248660842 to your computer and use it in GitHub Desktop.
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
from prefect import task, Flow | |
@task(log_stdout=True) | |
def bus_logic_etl_1(): | |
print("Executing bus_logic_etl_1") | |
@task(log_stdout=True) | |
def bus_logic_etl_2(): | |
print("Executing bus_logic_etl_2") | |
@task(log_stdout=True) | |
def bus_logic_etl_3(): | |
print("Executing bus_logic_etl_3") | |
with Flow("business_logic_layer") as flow: | |
etl_1 = bus_logic_etl_1() | |
etl_2 = bus_logic_etl_2() | |
etl_3 = bus_logic_etl_3() | |
etl_1.set_downstream(etl_2) | |
etl_2.set_downstream(etl_3) | |
if __name__ == '__main__': | |
flow.register("InterFlow_Dependencies") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment