resq-perf 0.1.10

Real-time CPU and memory performance TUI for ResQ platform
resq-perf-0.1.10 is not a library.

resq-perf — Performance Dashboard

Ratatui terminal UI showing live CPU usage, memory consumption, and request metrics for ResQ services. Pulls data from the services' /status endpoints (compatible with coordination-hce).

Build

# Build from workspace root
cargo build --release -p resq-perf

Binary: target/release/resq-perf

Usage

# Monitor HCE service (default: http://localhost:3000/admin/status)
resq-perf

# Target a specific service status URL (positional argument)
resq-perf http://localhost:3000/admin/status

# Authenticated service (reads RESQ_TOKEN env var)
resq-perf --token eyJhbGc...

# Adjust refresh rate in milliseconds
resq-perf --refresh-ms 1000

Environment variables are also accepted:

export RESQ_TOKEN=eyJhbGc...
resq-perf http://localhost:3000/admin/status

TUI Layout

┌─ ResQ Performance Monitor ──────────────────────────────────┐
│ Service: coordination-hce @ http://localhost:3000  [Tab: next]│
├────────────────────────────────────────────────────────────┤
│ CPU Usage          Memory              Requests/sec         │
│ ████████░░ 78%     ██████░░ 1.2/2 GB   ████░░ 207 req/s    │
├────────────────────────────────────────────────────────────┤
│ Latency Percentiles                                        │
│   p50:  45ms    p95: 120ms    p99: 350ms                   │
├────────────────────────────────────────────────────────────┤
│ Recent (60s)                                               │
│ CPU  ▁▂▃▄▅▆▇█▇▆▅▄▃▂▁▂▃▄▅▆▇█▇▆▅                           │
│ Mem  ▃▃▄▄▄▅▅▅▅▄▄▄▄▃▃▃▄▄▅▅▅▅▄▄▄                           │
├────────────────────────────────────────────────────────────┤
│ [q] quit   [Tab] next service   [r] refresh                │
└────────────────────────────────────────────────────────────┘

Keyboard Shortcuts

Key Action
q Quit
Tab Cycle to next service
r Force immediate refresh

Authentication

The performance monitor supports Bearer token authentication via the --token flag or the RESQ_TOKEN environment variable. This is compatible with the coordination-hce service's admin endpoints.

Flags

Argument / Flag Default Description
url http://localhost:3000/admin/status Positional: status endpoint to monitor
--token <jwt> $RESQ_TOKEN Bearer token for authenticated services
--refresh-ms <ms> 500 Refresh interval in milliseconds

Related

For point-in-time CPU flame graphs rather than live dashboards, use flame-graph.

For comprehensive profiling workflows see docs/PROFILING_FLAMEGRAPH_GUIDE.md.