Airflow - Branching join operators

Viewed 1317

I am trying to join branching operators in Airflow

I did this :

op1>>[op2,op3,op4]
op2>>op5
op3>>op6
op4>>op7
[op5,op6,op7]>>op8

It gives a schema like this with relations between op2, op3, op4 and op8.

current airflow dag

How do I get this:

desired airflow dag

2 Answers

can you be more clear ? I tried using your chain function and I can do what you wanted. enter image description here

First of all: can you be more specific as to the exact code you use to set the relationships between the tasks?

Second: you could try using the chain function. If you look at the last example in the relationship-builders section, that should be pretty much what you are trying to achieve right?

Third: you can use airflow show_dag to easily visualize your dag.

Related