pub trait ChildLauncher: Send + Sync {
// Required methods
fn spawn<'life0, 'life1, 'async_trait>(
&'life0 self,
spec: &'life1 ChildSpec,
) -> Pin<Box<dyn Future<Output = Result<ChildRef, RuntimeError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn terminate<'life0, 'life1, 'async_trait>(
&'life0 self,
child: &'life1 ChildRef,
grace: Duration,
) -> Pin<Box<dyn Future<Output = Result<Option<i32>, RuntimeError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn probe<'life0, 'life1, 'async_trait>(
&'life0 self,
project_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = ChildProbe> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
The OS side of the logical adapter.
Required Methods§
Sourcefn spawn<'life0, 'life1, 'async_trait>(
&'life0 self,
spec: &'life1 ChildSpec,
) -> Pin<Box<dyn Future<Output = Result<ChildRef, RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn spawn<'life0, 'life1, 'async_trait>(
&'life0 self,
spec: &'life1 ChildSpec,
) -> Pin<Box<dyn Future<Output = Result<ChildRef, RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Launch a child kernel for spec. Refuses a project that already has
a live child.
Sourcefn terminate<'life0, 'life1, 'async_trait>(
&'life0 self,
child: &'life1 ChildRef,
grace: Duration,
) -> Pin<Box<dyn Future<Output = Result<Option<i32>, RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn terminate<'life0, 'life1, 'async_trait>(
&'life0 self,
child: &'life1 ChildRef,
grace: Duration,
) -> Pin<Box<dyn Future<Output = Result<Option<i32>, RuntimeError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Stop it: graceful shutdown first, then terminate after grace.
Returns the exit code when known.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".