blag commented on code in PR #26347:
URL: https://github.com/apache/airflow/pull/26347#discussion_r981810841


##########
airflow/jobs/scheduler_job.py:
##########
@@ -1227,6 +1222,19 @@ def _update_state(dag: DAG, dag_run: DagRun):
                 active_runs_of_dags[dag_run.dag_id] += 1
                 _update_state(dag, dag_run)
 
+    @retry_db_transaction
+    def _schedule_all_dag_runs(self, guard, dag_runs, session):
+        """Makes scheduling decisions for all `dag_runs`"""
+        callback_tuples = []
+        callback_to_run = None
+        for dag_run in dag_runs:
+            callback_to_run = self._schedule_dag_run(dag_run, session)
+            callback_tuples.append((dag_run, callback_to_run))
+
+        guard.commit()
+
+        return callback_tuples, callback_to_run

Review Comment:
   I don't strongly prefer a dict, that's just what makes more sense to me. But 
yeah, if a list works then go with that.



-- 
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]

Reply via email to