Skip to content

Add DAG run missed-deadline metadata to Grid API#62189

Merged
ferruzzi merged 12 commits intoapache:mainfrom
imrichardwu:error-ui-backend
Feb 20, 2026
Merged

Add DAG run missed-deadline metadata to Grid API#62189
ferruzzi merged 12 commits intoapache:mainfrom
imrichardwu:error-ui-backend

Conversation

@imrichardwu
Copy link
Copy Markdown
Contributor

@imrichardwu imrichardwu commented Feb 19, 2026

This PR introduces backend and API support for exposing per-DAG-run deadline information to the UI.

Changes included

API and data model

  • GridRunsResponse gains a has_missed_deadline: bool field, allowing the Grid view to surface
    deadline status without additional API calls.

New private UI endpoint

  • Adds a private UI router mounted at /ui/deadlines/{dag_id}/{run_id}.
  • The endpoint fetches all Deadline rows for the given DAG run, joined with their associated
    DeadlineAlert records.
  • Results are ordered by deadline_time and returned as DeadlineResponse objects.

New response model

DeadlineResponse includes:

  • id
  • deadline_time
  • missed
  • created_at
  • alert_name (nullable)
  • alert_description (nullable)

OpenAPI

  • Updates _private_ui.yaml to document the new endpoint and response schema.
  • Regenerates the TypeScript client accordingly.

Notes

  • No UI rendering logic is included in this PR.
  • This PR only exposes the data required by the UI, keeping frontend concerns separate.

Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)


Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

…G runs

- Added DeadlinesService and new /deadlines route for fetching DAG run deadlines
- Added deadline datamodels (DeadlineResponse, DeadlineCollectionResponse)
- Added has_missed_deadline field to GridDAGRunwithTIDetails
- Registered deadlines router in UI routes
- Updated OpenAPI spec and regenerated openapi-gen client files
@boring-cyborg boring-cyborg bot added area:API Airflow's REST/HTTP API area:UI Related to UI/UX. For Frontend Developers. labels Feb 19, 2026
@imrichardwu imrichardwu changed the title Error UI backend Add DAG run missed-deadline metadata to Grid API Feb 19, 2026
Copy link
Copy Markdown
Contributor

@ferruzzi ferruzzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The yaml and python portions look like they are following the patterns of the surrounding code. The typescript portion is absolute witchcraft but I think it looks right compared the surrounding code for other features.

Approving with the caveat that someone with more front-end experience needs to also approve it, and assuming the CI goes green

@ferruzzi ferruzzi requested a review from vincbeck February 20, 2026 00:13
@imrichardwu imrichardwu requested a review from vincbeck February 20, 2026 15:47
@ferruzzi ferruzzi merged commit 3130fff into apache:main Feb 20, 2026
129 checks passed
@imrichardwu imrichardwu deleted the error-ui-backend branch February 21, 2026 01:22
choo121600 pushed a commit to choo121600/airflow that referenced this pull request Feb 22, 2026
* feat: add deadlines API endpoint and has_missed_deadline field for DAG runs

- Added DeadlinesService and new /deadlines route for fetching DAG run deadlines
- Added deadline datamodels (DeadlineResponse, DeadlineCollectionResponse)
- Added has_missed_deadline field to GridDAGRunwithTIDetails
- Registered deadlines router in UI routes
- Updated OpenAPI spec and regenerated openapi-gen client files
Copy link
Copy Markdown
Member

@pierrejeambrun pierrejeambrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll open a follow up PR to fix some issues here. (General design, pagination is missing, ordering options, payload format etc....)

Please if you have any doubt wait for additional reviews before merging.

dominikhei pushed a commit to dominikhei/airflow that referenced this pull request Mar 11, 2026
* feat: add deadlines API endpoint and has_missed_deadline field for DAG runs

- Added DeadlinesService and new /deadlines route for fetching DAG run deadlines
- Added deadline datamodels (DeadlineResponse, DeadlineCollectionResponse)
- Added has_missed_deadline field to GridDAGRunwithTIDetails
- Registered deadlines router in UI routes
- Updated OpenAPI spec and regenerated openapi-gen client files
Ankurdeewan pushed a commit to Ankurdeewan/airflow that referenced this pull request Mar 15, 2026
* feat: add deadlines API endpoint and has_missed_deadline field for DAG runs

- Added DeadlinesService and new /deadlines route for fetching DAG run deadlines
- Added deadline datamodels (DeadlineResponse, DeadlineCollectionResponse)
- Added has_missed_deadline field to GridDAGRunwithTIDetails
- Registered deadlines router in UI routes
- Updated OpenAPI spec and regenerated openapi-gen client files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:API Airflow's REST/HTTP API area:UI Related to UI/UX. For Frontend Developers.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants