Skip to content

Scheduling Workflows

Scheduled runs use a schedule trigger plus a schedule YAML. The workflow itself has no embedded invocation.

For HTTP / AMQP / dashboard starts, see Triggers.

Prerequisites

  • A trigger with invocation.type: schedule targeting the workflow (e.g. flows/triggers/heartbeat-timestamp-schedule.yaml or minimal-scheduled.yaml).
  • A schedule document under flows/schedules/ with workflow, cron_expression, and optional payload.
  • Scheduler service deployed and reachable.

Schedule YAML fields

Field Description
name Unique schedule name (job id: yaml:{name})
workflow Workflow to start
cron_expression Standard 5-field cron (minute hour day month weekday)
payload Optional XML (or string) body sent to the workflow
enabled When false, the schedule is not registered
description Optional operator text

There is no cron / payload_xml field — use cron_expression and payload.

Example: heartbeat

Trigger (flows/triggers/heartbeat-timestamp-schedule.yaml):

name: heartbeat-timestamp-schedule
target_workflow: heartbeat_timestamp
group: samples
description: Internal scheduler / cron — heartbeat timestamp workflow.
example_payloads:
  - name: tick
    payload:
      xml: "<heartbeat><tick/></heartbeat>"
invocation:
  type: schedule

Schedule (flows/schedules/heartbeat-every-minute.yaml):

name: heartbeat-every-minute
workflow: heartbeat_timestamp
cron_expression: "* * * * *"
payload: "<heartbeat/>"
enabled: false
description: "Heartbeat schedule every minute (timestamp-only workflow) — disabled"

Workflow (flows/workflows/heartbeat_timestamp.yaml) — steps only; no invocation.

Same pattern for minimal: trigger minimal-scheduled + a schedule that sets workflow: minimal.

Nightly template

flows/schedules/nightly-demo.yaml shows the field set (cron_expression: "0 0 * * *", payload: "<root/>", enabled: false). Point workflow at a real workflow that has a schedule trigger.

Verify schedule execution

  • List schedules through scheduler / dashboard.
  • Enable a schedule (enabled: true), wait for a tick, then check traces and trigger events.
  • Confirm the bound schedule trigger appears on the workflow in the dashboard.