Skip to content

wp datamachine flows list times out with ~300 flows #934

@chubes4

Description

@chubes4

Problem

Running wp datamachine flows list on the events site (336 flows) timed out after 30 seconds. This is not a large dataset — the command likely does N+1 queries (loading full flow configs, pipeline joins, or scheduling status checks per row).

Impact

Agents and operators can't quickly check flow status via CLI. The events site is the primary consumer and 336 flows should be well within acceptable performance.

Likely Cause

The command probably:

  • Loads full flow_config and scheduling_config JSON blobs per row
  • Joins to pipelines table without index optimization
  • Possibly resolves execution status from the jobs table per flow

Suggestion

  • Add a --fields flag to limit which columns are fetched (skip large JSON blobs by default)
  • Add pagination (--per-page, --page)
  • Consider a summary mode that only shows flow_id, name, pipeline, interval, and last run status
  • Ensure the query uses indexed lookups

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions