Skip to main content

Module action

Module action 

Source
Expand description

Cross-thread ApiAction / ApiResponse enums.

Per 10-data-model.md § 4.1, the API layer never touches device or hypervisor state directly. Mutating handlers serialize through this enum onto a bounded mpsc channel; the VMM event loop consumes the channel one action at a time.

ApiAction carries fully-validated payloads. Construction of any variant from raw JSON goes through the corresponding Raw* → newtype TryFrom, so the VMM event loop never has to re-validate.

Enums§

ActionClass
Per-action class used to look up the tokio::time::timeout budget for an action (70-security.md § 6).
ApiAction
Mutating action posted onto the API → VMM channel.
ApiResponse
Response posted back through the oneshot paired with each ApiAction.