malthe edited a comment on issue #17010:
URL: https://github.com/apache/airflow/issues/17010#issuecomment-966888936
I think something like `TriggerRule.WAIT_ALL & TriggerRule.ONE_SUCCESS` is
easier to understand than the existing `TriggerRule.NONE_FAILED_OR_SKIPPED`
rule.
Following the ideas in #19361 – it seems that these ideas can combine, e.g.
```python
...
trigger_rule=TriggerRule.WAIT_ALL & TriggerRule.ONE_SUCCESS &
TriggerRule.MONDAY
```
Those are all static rules that can be combined with boolean logic such as
`&`, `|` and `~` (not).
(This assumes that `TriggerRule.<name>` are no longer just simple strings,
but support these logical operators. For backwards compatibility, a simple
string would still work until the next major version.)
In #19361 there is also `CronTimeFilter` which could be turned into a
trigger rule as well – in the example above, `TriggerRule.MONDAY` is really
just a predefined cron-based time filter.
Like timetables (see
[AIP-39](https://cwiki.apache.org/confluence/display/AIRFLOW/AIP-39+Richer+scheduler_interval)),
there could be support for custom implementations, but it might be reasonable
to start with a set of builtin classes which can then be combined as proposed
above.
In some scheduling systems, there is support for custom calendars such as
"bank holidays". This seems like a good case for a custom implementation since
there is no clear single solution. There are Python libraries such as
[holidays](https://pypi.org/project/holidays/) that address official holidays,
but an organization might have a need for much more specific calendars.
--
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]