Qian Yu created AIRFLOW-5840:
--------------------------------

             Summary: Add a link to the external task that ExternalTaskSensor 
is waiting for
                 Key: AIRFLOW-5840
                 URL: https://issues.apache.org/jira/browse/AIRFLOW-5840
             Project: Apache Airflow
          Issue Type: Improvement
          Components: operators
    Affects Versions: 1.10.6
            Reporter: Qian Yu


When using ExternalTaskSensor, there's no indication on the Web UI regarding 
which task the sensor is waiting for. Does anyone have ideas for improving 
this? 

One idea is to override the get_link() abstract method of ExternalTaskSensor 
and point it to the task that the sensor waits for. Maybe something like this 
(just for demo, not tested and likely not working):
{code:python}
def get_link(self, operator: BaseOperator, dttm: datetime) -> str:
     return 
"{}?dag_id={}&task_id={}&execution_date={}".format(conf["base_url"], 
self.external_task_id, self.execution_date.isoformat())
{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to