Trait wasmer_wasix::runners::wcgi::Callbacks
source · pub trait Callbacks: Debug + Send + Sync + 'static {
// Provided methods
fn started(&self, _abort: AbortHandle) { ... }
fn on_stderr(&self, _stderr: &[u8]) { ... }
fn on_stderr_error(&self, _error: Error) { ... }
fn recycle_env<'life0, 'async_trait>(
&'life0 self,
conf: RecycleEnvConfig,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
fn create_env<'life0, 'async_trait>(
&'life0 self,
conf: CreateEnvConfig,
) -> Pin<Box<dyn Future<Output = Result<CreateEnvResult>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait { ... }
}
Expand description
Callbacks that are triggered at various points in the lifecycle of a runner and any WebAssembly instances it may start.
Provided Methods§
sourcefn started(&self, _abort: AbortHandle)
fn started(&self, _abort: AbortHandle)
A callback that is called whenever the server starts.
sourcefn on_stderr_error(&self, _error: Error)
fn on_stderr_error(&self, _error: Error)
Reading from stderr failed.
sourcefn recycle_env<'life0, 'async_trait>(
&'life0 self,
conf: RecycleEnvConfig,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn recycle_env<'life0, 'async_trait>(
&'life0 self,
conf: RecycleEnvConfig,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Recycle the WASI environment
sourcefn create_env<'life0, 'async_trait>(
&'life0 self,
conf: CreateEnvConfig,
) -> Pin<Box<dyn Future<Output = Result<CreateEnvResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn create_env<'life0, 'async_trait>(
&'life0 self,
conf: CreateEnvConfig,
) -> Pin<Box<dyn Future<Output = Result<CreateEnvResult>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create the WASI environment