2026-02-09 09:04:57 +00:00
|
|
|
[package]
|
|
|
|
|
name = "runtime-dashboard"
|
|
|
|
|
version = "0.1.0"
|
|
|
|
|
edition = "2024"
|
|
|
|
|
|
|
|
|
|
[dependencies]
|
|
|
|
|
swactor = { path = "../..", features = ["serde", "tracing"] }
|
|
|
|
|
tracing = "0.1"
|
|
|
|
|
tracing-subscriber = { version = "0.3", features = ["registry"] }
|
|
|
|
|
serde = { version = "1", features = ["derive"] }
|
|
|
|
|
serde_json = "1"
|
|
|
|
|
tiny_http = "0.12"
|
2026-02-11 15:23:26 +00:00
|
|
|
crossbeam-queue = "0.3.12"
|
|
|
|
|
ratatui = { version = "0.29", optional = true, default-features = false, features = ["crossterm"] }
|
|
|
|
|
crossterm = { version = "0.28", optional = true }
|
2026-02-12 09:13:50 +00:00
|
|
|
distribution = { path = "../distribution", optional = true }
|
feat: command interface — frontend-agnostic dispatch crate
Add swactor-command crate that decouples command dispatch from the
dashboard, enabling the same commands from REPL, REST, TUI, or any
future frontend.
- CommandRouter with dispatch(), CommandHandler trait, CommandMeta
- CommandRequest/CommandResponse (serde-serializable JSON protocol)
- CommandContext with Arc<Runtime> + optional StatsEnricher trait
- 9 built-in commands extracted from investigate.rs:
help, overview, workers, worker, actors, actor, hot, phases, diff,
shutdown
- REPL line parser (parse_line) with positional arg mapping
- REST adapter (from_query_params) for HTTP query parameters
- Dashboard integration: StatsEnricher impl for StatsCollector,
investigate.rs refactored to thin CommandRouter wrapper,
server.rs updated to share CommandRouter across handler threads
- 18 behavioral tests in crates/command/tests/command_api.rs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-12 18:03:30 +00:00
|
|
|
swactor-command = { path = "../command" }
|
2026-02-11 15:23:26 +00:00
|
|
|
|
2026-02-12 09:13:50 +00:00
|
|
|
[dependencies.ctrlc]
|
|
|
|
|
version = "3"
|
2026-02-11 15:23:26 +00:00
|
|
|
|
|
|
|
|
[features]
|
2026-02-12 09:13:50 +00:00
|
|
|
default = ["distribution"]
|
2026-02-11 15:23:26 +00:00
|
|
|
tui = ["dep:ratatui", "dep:crossterm"]
|
2026-02-12 09:13:50 +00:00
|
|
|
distribution = ["dep:distribution"]
|
2026-02-11 15:23:26 +00:00
|
|
|
|
2026-02-12 09:13:50 +00:00
|
|
|
[[bin]]
|
|
|
|
|
name = "swactor-tui"
|
|
|
|
|
path = "src/bin/tui.rs"
|
2026-02-11 15:23:26 +00:00
|
|
|
required-features = ["tui"]
|