yuqian90 opened a new pull request #10153:
URL: https://github.com/apache/airflow/pull/10153


   This is still work-in-progress. i really liked @ashb and a few other 
people's idea of having TaskGroup entirely as a "UI grouping concept". It's 
much simpler than the existing `SubDagOperator` approach. With some syntax 
sugar such as `__rshift__` and `__lshift__`, creating repeated/nested sections 
in a DAG can be made much easier.
   
   @xinbinhuang already attempted this in 
https://github.com/apache/airflow/pull/9243. I'm trying to simplify the idea 
further.
   In this PR, `TaskGroup` is just a utility class used to constructions 
sub-sections in a DAG. It does not need to be persisted to db at all. The only 
thing the UI needs to know is the `task_group.group_id` of a task. Once we know 
the group_id, I'm sure we can do something to the Web UI to put tasks in the 
same group_id close together as a single node (The UI part has not been done in 
this PR).
   
   This is the example_task_group that this PR adds:
   When zoomed out, the DAG graph should look like this:
   
![image](https://user-images.githubusercontent.com/6637585/89280726-9d80b200-d67b-11ea-8d15-632635ce5dea.png)
   
   When zoomed in, the DAG graph should look like this:
   
![image](https://user-images.githubusercontent.com/6637585/89280731-a2456600-d67b-11ea-9d6c-056bd08e8438.png)


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to