Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add reprocessing behavior for backfill #43382

Merged

Conversation

dstandish
Copy link
Contributor

@dstandish dstandish commented Oct 25, 2024

User can decide whether we should create a new run or not when a run already exists. For now, we just look at the latest instance of the by start date. If it's in flight we do not create. If it's done, we may or may not create depending on state and desired reprocessing behavior.

There are three options for reprocessing behavior:

  1. none
  • if there's already a run for this logical date, do not create another, no matter the state
  1. failed
  • if a run exists, if the state is failed, create a new run for this date
  1. completed
  • if a run exists, if the state is completed or failed, create a new run for this date

If the latest run is still running or is queued, we do not create another run, no matter the chosen reprocessing behavior.

@dstandish dstandish force-pushed the aip-78-clearing-behavior-just-add-dag-runs branch 2 times, most recently from 16227d5 to c6b7a26 Compare October 25, 2024 15:01
@dstandish dstandish force-pushed the aip-78-clearing-behavior-just-add-dag-runs branch from aff73d0 to 991e68c Compare October 25, 2024 22:54
@dstandish
Copy link
Contributor Author

Alright this should be good to go. Think I have it to pretty stable place / sensible behavior.

Copy link
Contributor

@jscheffl jscheffl left a comment

Choose a reason for hiding this comment

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

I don't know if I asked before... no API changes on FastAPI? Still building this function on the legacy API which should go away?

@dstandish dstandish added the legacy api Whether legacy API changes should be allowed in PR label Oct 26, 2024
@dstandish
Copy link
Contributor Author

dstandish commented Oct 26, 2024

I don't know if I asked before... no API changes on FastAPI? Still building this function on the legacy API which should go away?

the project began before the new API was there and i just wanted to focus on finishing the AIP. we will need to migrate it. also, from looking at some of the migrated routes i'm not sure if the security part of things has been figured out yet either.

@dstandish dstandish added the legacy ui Whether legacy UI change should be allowed in PR label Oct 26, 2024
@dstandish dstandish force-pushed the aip-78-clearing-behavior-just-add-dag-runs branch from 414534a to 4364927 Compare October 26, 2024 21:14
User can decide whether we should create a new run or not when a run already exists. For now, we just look at the latest instance of the by start date. If it's in flight we do not create.  If it's done, we may or may not create depending on state and desired reprocessing behavior.
@dstandish dstandish force-pushed the aip-78-clearing-behavior-just-add-dag-runs branch from 01b7b6a to c70441c Compare October 28, 2024 16:49
@dstandish dstandish merged commit c2e4d21 into apache:main Oct 28, 2024
52 checks passed
@dstandish dstandish deleted the aip-78-clearing-behavior-just-add-dag-runs branch October 28, 2024 20:43
ellisms pushed a commit to ellisms/airflow that referenced this pull request Nov 13, 2024
User can decide whether we should create a new run or not when a run already exists. For now, we just look at the latest instance of the by start date. If it's in flight we do not create.  If it's done, we may or may not create depending on state and desired reprocessing behavior.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:db-migrations PRs with DB migration kind:documentation legacy api Whether legacy API changes should be allowed in PR legacy ui Whether legacy UI change should be allowed in PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants