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

Programmatically prune existing zombie flows. #16727

Open
EmilRex opened this issue Jan 15, 2025 · 1 comment
Open

Programmatically prune existing zombie flows. #16727

EmilRex opened this issue Jan 15, 2025 · 1 comment
Labels
enhancement An improvement of an existing feature

Comments

@EmilRex
Copy link
Contributor

EmilRex commented Jan 15, 2025

Describe the current behavior

Automations are great for managing my flow runs, but only on a post-creation basis. Say for example I have an infrastructure outage that leaves hundreds of flows in a Pending state. An automation that "marks flow runs as crashed after being in a Pending state for at least an hour" would handle these flow runs, but only if the automation existed already.

Describe the proposed behavior

An option to apply an automation retroactively, for example by replaying events from a particular point in time, would be one way to help users manage state on an aggregate level.

Example Use

No response

Additional context

Certainly there are other ways to accomplish this, for example by adding bulk state update functionality. This is just one proposal.

@EmilRex EmilRex added the enhancement An improvement of an existing feature label Jan 15, 2025
@aaazzam
Copy link
Collaborator

aaazzam commented Jan 15, 2025

@EmilRex I like the problem here:

  • I use automations to prune zombie flows.
  • I want to prune existing zombie flows that predate my automations.

Current design of the automation system makes this proposed solution a bit intractable, as it would have to go back and replay all events from the workspace that matched the automation. The juice may not be worth the squeeze, until we hear more about folks wanting to replay other types of automations for broader applications.

Bulk settings states, or the ability to mutate state for some QuerySet of flows makes a ton of sense, and has come up a few times before (especially in the UI where folks want to cancel runs over multiple pages of the UI).

Would that address the problem laid out here?

@aaazzam aaazzam changed the title Retroactively apply automations Programmatically prune existing zombie flows. Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

2 participants