0

I have two tasks.

  1. T05:30 - I wish for this to run at 05:30 every day.
  2. T08:30 - I wish for this to run at 08:30 every day, but only if T05:30 has succeeded today.

Can this be achieved in Airflow? It appears that dependencies (i.e. run T8:30 only if only if T05:30 has succeeded today) are a task-only concept but schedules (05:30 every day and 08:30 every day) are a DAG-only concept.

I could hack this by checking variables or something external, but I'm hoping that there is an idiomatic solution to this.

1

1 Answer 1

0

Maybe you could use a sensor https://airflow.apache.org/docs/apache-airflow/stable/howto/operator/time.html

Think in the dependencies defined ( task_1 >> sensor >> task_2) task_1 will run at 5h30, if it sucessed it will run the sensor (it`ll wait until 8h30) and finally running the task_2.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.