M0.7: control channel over JSON lines
lutra_control::start binds 127.0.0.1:PORT and serves app.ping, engine.execute, engine.listCommands and ui.screenshot through the Backend trait the host implements. Lines are capped at 16 MiB, every input gets a well-formed response with a stable error code, and backend panics become internal errors. Proptests cover arbitrary lines; a TCP integration test uses the new testkit EngineBackend. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
07adedadbd
commit
a3f83102f1
9 changed files with 979 additions and 3 deletions
|
|
@ -1,4 +1,14 @@
|
|||
//! Control channel of Lutra (layer L5).
|
||||
//!
|
||||
//! Serves JSON lines on a local TCP port so that scripts and agents can run
|
||||
//! engine commands and inspect the user interface.
|
||||
//! Serves JSON lines on `127.0.0.1:PORT` so that scripts and agents can run
|
||||
//! engine commands and inspect the user interface. The protocol is described
|
||||
//! in docs/architecture.md › Control channel; [`protocol`] parses and answers
|
||||
//! single lines, [`server`] owns the sockets. Hosts plug in through
|
||||
//! [`Backend`].
|
||||
|
||||
mod backend;
|
||||
pub mod protocol;
|
||||
pub mod server;
|
||||
|
||||
pub use backend::Backend;
|
||||
pub use server::{ServerHandle, start};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue