Skip to content

Add allowed_run_types parameter to Dag class #45146

@eladkal

Description

@eladkal

Body

Some workflows are designed to be purely automatic. We should allow the capability for DAG author to declare DAG as scheduled run only. This means:

  1. Create manual run button from the UI will generate error / be disabled.
  2. Create manual run from API will generate error.
  3. Scheduler will not run tasks of manual DagRuns if the parameter is set.

To allow flexibility I'm proposing the allowed_run_types should be enum ['Scheduled', 'Backfill', 'Manual'] where user choose what to set. Thus we need to define the set of allowed rules per type.

Committer

  • I acknowledge that I am a maintainer/committer of the Apache Airflow project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:APIAirflow's REST/HTTP APIarea:UIRelated to UI/UX. For Frontend Developers.area:corekind:featureFeature Requests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions