Crate wasmcloud_actor_core[−][src]
Core wasmCloud Actor Interface
All wasmCloud actors must respond to the core health request message, and all capability providers must be able to receive binding configuration according to the CapabilityConfiguration struct.
Example
extern crate wasmcloud_actor_core as actorcore; use wapc_guest::HandlerResult; use actorcore::{HealthCheckRequest, HealthCheckResponse, Handlers}; #[no_mangle] pub fn wapc_init() { Handlers::register_health_request(health); } fn health(_msg: HealthCheckRequest) -> HandlerResult<HealthCheckResponse> { Ok(HealthCheckResponse::healthy()) }
Structs
CapabilityConfiguration | |
Handlers | Used to register core message handlers |
HealthCheckRequest | A request sent to the actor by the host itself in order to determine health status |
HealthCheckResponse | All actors must return a health check response to the host upon
receipt of a health request. Returning in |
Functions
deserialize | The standard function for de-serializing codec structs from a format suitable for message exchange between actor and host. Use of any other function to deserialize could result in breaking incompatibilities. |
serialize | The standard function for serializing codec structs into a format that can be used for message exchange between actor and host. Use of any other function to serialize could result in breaking incompatibilities. |