Skip to main content

Module engine

Module engine 

Source
Expand description

Engine — the long-running stateful runtime plus the with_state helper (R1-R4 discipline).

The engine owns the Domain side of the Data / Domain split: flow control (dispatch / verdict), state (EngineState), and the submit_output / output_tail surface that feeds it. Data-plane traffic (Big Response bodies) is delegated to the output_store module plus its paired SpawnerLayers and passes through here without the engine core needing to grow.

Structs§

Engine
Process-wide long-running runtime. Cheap to clone() — an Arc lives inside.

Enums§

FoldParse
How [fold_final_and_parts] treats Value::String content when assembling the BP-chain value — the fold half of the SUBMIT_FORMAT_KEY contract.

Constants§

SUBMIT_FORMAT_KEY
AgentContextView.extra key carrying a step’s declared submit format. Declared through the GH #21 meta channels (Blueprint.metas / AgentMeta.ctx / step-level $step_meta) and folded into the view at spawn time by AgentContextMiddleware. Read in two places: the HTTP submit lane (mlua-swarm-server’s resolve_submit_value, where "json" means strict parse-or-422) and Engine::fold_parse_mode_for (where SUBMIT_FORMAT_TEXT opts the step’s fold out of the default lenient container parse — see FoldParse).
SUBMIT_FORMAT_TEXT
The SUBMIT_FORMAT_KEY value that opts a step’s fold out of lenient container parsing (FoldParse::Raw): every string the worker submitted — final body and staged parts alike — folds into the flow ctx as itself, even when its bytes would parse as a JSON object or array.