Skip to main content

Crate frame_host

Crate frame_host 

Source
Expand description

The full frame server: one binary, one config, one start command.

frame-host --config frame.toml boots the entire stack in a single process:

  • the embedded liminal component (embedded) — liminal’s TCP wire listener, browser WebSocket listener, and health endpoint, running in-process on liminal’s own threads (no child process, no side-by-side server); the host owns its lifecycle but not its bytes;
  • the frame-core host authority (runtime) — the host-owned capability table reached only through frame_core::capability::HostCapabilityFacade, the component registry, and supervised lifecycle, around the class-(b) client-native graph view under the frame:graph-view@v1 contract (D10);
  • the console HTTP server (server) — the static browser bundle, GET /frame/config.json, GET /frame/app/status.json (the application-truth snapshot, truth), and the same-origin /frame/bus/* health proxy routes (bus_proxy).

Per ruling D3 the browser is a bus PARTICIPANT: the served page connects to the embedded bus directly over the WebSocket transport. This host never proxies or terminates that feed; /frame/config.json is DERIVED at runtime from the embedded component’s real bound WebSocket address (served as busEndpoint), so the page’s endpoint and the server’s address can never drift.

Console-first (D9): every component lifecycle transition and capability denial is logged to stdout as it happens.

§The embedding seam

frame-host is also a library: an embedding application supplies an AppSpec (its component installs, stated runtime policy, readiness proof, and fact announcements) and run_application boots the whole stack around it — app is this binary’s own composition riding the same seam. The announcer publishes the host authority’s real events (lifecycle transitions, capability denials, application facts) on [frame].channel over its OWN native participant connection: the page server still carries zero feed bytes (D3) — the host is a node on the bus, never a proxy in front of it.

Re-exports§

pub use announcer::Announcer;
pub use app::run;
pub use application::Application;
pub use application::run_application;
pub use application::run_dev_application;
pub use cli::Cli;
pub use config::DocumentSection;
pub use config::FrameConfig;
pub use config::FrameSection;
pub use error::HostError;
pub use page::PageServer;
pub use spec::AppError;
pub use spec::AppSpec;
pub use spec::ComponentInstall;
pub use syntax_theme::default_syntax_theme;
pub use truth::AppTruth;
pub use truth::AppTruthSnapshot;

Modules§

announcer
The application-event announcer (design §4.3): an in-process NATIVE bus participant that publishes the host authority’s real events onto [frame].channel as JSON — component lifecycle transitions and capability denials (from the same registry lifecycle subscription that feeds the console logger) plus application-announced facts.
app
The frame-host binary’s own application composition — the FIRST consumer of the embedding seam (design §4.2’s unwired-seam rule: every seam entry point has a production caller at the bytes).
application
The embedding seam’s orchestration (design §4.1/§4.2): boot the full stack around an application’s AppSpec, serve until a stop, tear the whole stack down in order.
bus_proxy
Same-origin proxy routes for the embedded bus’s health listener.
cli
Command line for the full frame server.
config
The single frame.toml that describes the whole stack.
dev
The frame:dev-management@v1 vocabulary: the S1/S2 schema frame dev and the generated host SHARE (F-7b R5 — frame-cli adapts this vocabulary; it does not fork it).
doc_binding
The document-service transport binding (IRIDIUM-A3 R11, C1 as ruled): frame-host is the thin embedding host — the service logic lives in frame-doc-service; THIS module owns only the concrete bus wiring:
embedded
The embedded liminal component.
error
Typed failures for every host boot, serve, and shutdown path.
manifest
Declaration of the demo component this host registers and supervises.
page
Page-server port resolution (2026-07-22 portless ruling).
runtime
Boot and ordered shutdown of the frame-core host authority around an embedding application’s component installs (design §4.2).
serve
Async serving of the console shell, coordinated with the embedded liminal component’s liveness and the process shutdown signals.
server
Static shell server for the browser client bundle.
spec
The embedding seam’s application contract (design §4.2): everything an embedding application supplies; frame-host supplies nothing.
syntax_theme
The built-in default syntax theme (IRIDIUM-A2 C5, amended 2026-07-21): a highlighter must visibly highlight out of the box, so frame-host ships a default capture-name → #rrggbb palette rather than leaving the wire’s optional syntaxTheme member perpetually absent.
truth
The application-truth snapshot (2026-07-21 boot-visibility fix).