[−][src]Trait wasm_service::Runnable
Runnable trait for deferred tasks Deferred tasks are often useful for logging and analytics.
Required methods
#[must_use]pub fn run<'life0, 'async_trait>(
&'life0 self,
lq: Rc<Mutex<LogQueue>>
) -> Pin<Box<dyn Future<Output = ()> + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
[src]
&'life0 self,
lq: Rc<Mutex<LogQueue>>
) -> Pin<Box<dyn Future<Output = ()> + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Execute a deferred task. The task may append
logs to lq
using the log
macro. Logs generated
are sent to the log service after all deferred tasks have run.
Note that if there is a failure sending logs to the logging service, those log messages (and the error from the send failure) will be unreported.