Lee-W commented on code in PR #58543:
URL: https://github.com/apache/airflow/pull/58543#discussion_r3026985951
##########
airflow-core/docs/authoring-and-scheduling/asset-scheduling.rst:
##########
@@ -147,6 +147,30 @@ If one asset is updated multiple times before all consumed
assets update, the do
}
+Gate scheduled runs on asset updates
+------------------------------------
+
+Use ``AssetAndTimeSchedule`` when you want a Dag to follow a normal time-based
timetable but only start after specific assets have been updated. Airflow
creates the DagRun at the scheduled time and keeps it queued until every
required asset has queued an event. When the DagRun starts, those asset events
are consumed so the next scheduled run waits for new updates. This does not
create additional asset-triggered runs.
+
+If ``dagrun_timeout`` is set on the DAG, it also limits how long an
``AssetAndTimeSchedule`` run may remain queued while waiting for its asset
condition to become ready.
Review Comment:
```suggestion
If ``dagrun_timeout`` is set on the Dag, it also limits how long an
``AssetAndTimeSchedule`` run may remain queued while waiting for its asset
condition to become ready.
```
##########
task-sdk/src/airflow/sdk/__init__.pyi:
##########
@@ -107,6 +108,7 @@ __all__ = [
"AssetAlias",
"AssetAll",
"AssetAny",
+ "AssetAndTimeSchedule",
Review Comment:
```suggestion
"AssetAndTimeSchedule",
"AssetAny",
```
We sort it in alphabetical order
##########
task-sdk/src/airflow/sdk/__init__.py:
##########
@@ -169,6 +171,7 @@
"AssetAlias": ".definitions.asset",
"AssetAll": ".definitions.asset",
"AssetAny": ".definitions.asset",
+ "AssetAndTimeSchedule": ".definitions.timetables.assets",
Review Comment:
```suggestion
"AssetAndTimeSchedule": ".definitions.timetables.assets",
"AssetAny": ".definitions.asset",
```
--
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]