1. Advisory PG lock on scheduler tick
Problem:/api/v1/cron/flow-scheduler-tick was lock-free. An external
orchestrator that double-fires the endpoint (e.g. a Vercel Cron retry on
a transient timeout) would dispatch every due pipeline twice.
Fix: Wrap the tick in pg_try_advisory_lock(0x666c6f77). When the
lock is already held, the route returns 200 with skipped: true so the
orchestrator doesn’t treat it as an error.
2. Per-tenant scheduler dashboard at /data/scheduler
A read-only page (no write controls) showing every IR-native pipeline
with ir.schedule:
| Column | Source |
|---|---|
| Pipeline name | pipelines.name |
| Schedule | ir.schedule (cron / interval / rrule) |
| Last run | pipelines.lastRunAt + lastRunStatus pill |
| Lag | Minutes between most-recent expected fire and actual lastRunAt — green if <5min, amber otherwise |
| Next 5 fires | Computed via the next-fire-times helper |
GET /api/v1/scheduler-status. Tenant-scoped via requireTenant.
3. k6 baseline perf script at k6/flow/baseline.js
Run with:
| Endpoint | p95 |
|---|---|
GET /api/v1/pipelines?limit=20 | <400ms |
GET /api/v1/pipelines/:id/ir | <400ms |
GET /api/v1/pipelines/:id/sql-preview | <800ms (info_schema lookup) |
GET /api/v1/lineage | <800ms (hits actual target table) |
http_req_failed: rate<0.01 (under 1% errors).
Honest limits deferred beyond Phase 6.6
| Item | Why deferred |
|---|---|
| Per-partition lag metrics for streaming consumers | Requires a real broker, gated by FLOW_STREAMING_ENABLED |
trigger.file_arrival.deadline enforcement | Requires source-watcher service; not yet built |
| Run-over-run trend chart on the per-node metrics drawer | Frontend chart component, not yet picked |
Selective replay-from-DLQ runtime (replayDlqOnly flag) | Source executor needs row-key filter capability |
| Visual DAG highlight on lineage row click | React Flow custom edge highlighting — polish plan |
| Drag-add-edge / right-click delete on Visual canvas | Polish plan |
| Editable per-node config form in right pane | Polish plan |
DLQ surfacing for non-validate failures (.failed/ folder rows) | Source executor needs to emit failure-folder index |