This interface defines the wasmCloud built-in logging interface that comes with each of our supported host runtimes. Actors that use this interface must have the capability contract wasmcloud:builtin:logging
in their claims list (wash claims sign --logging
).
There are no external implementations for this provider as they are built directly into the host runtime.
Logging at all available levels: ```rust use wasmbusrpc::actor::prelude::RpcResult; use wasmcloudinterface_logging::{debug, error, info, warn};
// Note: The function you're logging in must be async. This is due to the // way our logging macros work and is a known limitation of actor logging async fn logtoall() -> RpcResult<()> { debug!("Watch out for moths"); info!("This is an info level log!"); warn!("Some viewers may find the following log disturbing"); error!("I can't let you do that, Dave");
Ok(())
} ```