ephraimbuddy commented on a change in pull request #20391:
URL: https://github.com/apache/airflow/pull/20391#discussion_r781478624
##########
File path: airflow/jobs/scheduler_job.py
##########
@@ -395,6 +401,15 @@ def _executable_task_instances_to_queued(self, max_tis:
int, session: Session =
dag_id,
max_active_tasks_per_dag_limit,
)
+ # update the last_scheduling_decision for all task
instances in this dag
+ session.query(TI).filter(
+ TI.dag_id == task_instance.dag_id, TI.state ==
State.SCHEDULED
+ ).update(
+ {
+ TI.last_scheduling_decision: timezone.utcnow(),
+ },
+ synchronize_session=False,
Review comment:
My comment here was wrong, it actually updates only those in scheduled
state
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]