Skip to content

Workflow run retention policy #303

@thomasjiangcy

Description

@thomasjiangcy

Desired Behavior

It will be nice to have a way to configure retention period and automatically clean up workflows in terminal states without manual intervention, similar to Temporal's History Scavenger.

Possible design

// openworkflow.config.ts

export default defineConfig({
  ...,
  retention: {
    enabled: true,
    period: "30d", // shorthand, any workflow runs in terminal state past 30 days will be removed
  }
});

This is to keep it simple for now. In the future there could be more fine-grained control - e.g. frequency of this job, when to run it, customize what workflow run statuses to clean up.

I think there's a dependency on #246 before this can be considered.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions