pub trait ControlInterfaceServer: Send + Sync {
Show 19 methods
// Required methods
fn handle_auction_component<'life0, 'async_trait>(
&'life0 self,
request: ComponentAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ComponentAuctionAck>>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_auction_provider<'life0, 'async_trait>(
&'life0 self,
request: ProviderAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ProviderAuctionAck>>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_stop_host<'life0, 'async_trait>(
&'life0 self,
request: StopHostCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_scale_component<'async_trait>(
self: Arc<Self>,
request: ScaleComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait;
fn handle_update_component<'async_trait>(
self: Arc<Self>,
request: UpdateComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait;
fn handle_start_provider<'async_trait>(
self: Arc<Self>,
request: StartProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<()>>>> + Send + 'async_trait>>
where Self: 'async_trait;
fn handle_stop_provider<'life0, 'async_trait>(
&'life0 self,
request: StopProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_inventory<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<HostInventory>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_claims<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Vec<HashMap<String, String>>>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_links<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_config_get<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn handle_config_delete<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn handle_label_put<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabel,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn handle_label_del<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabelIdentifier,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn handle_link_put<'life0, 'async_trait>(
&'life0 self,
request: Link,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_link_del<'life0, 'async_trait>(
&'life0 self,
request: DeleteInterfaceLinkDefinitionRequest,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_registries_put<'life0, 'async_trait>(
&'life0 self,
request: HashMap<String, RegistryCredential>,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn handle_config_put<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
data: Bytes,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn handle_ping_hosts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Host>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Implementation for the server-side handling of control interface requests.
This trait is not a part of the wasmcloud_control_interface crate yet to allow
for the initial implementation to be done in the wasmcloud_host (pre 1.0) crate. This
will likely move to that crate in the future.
Required Methods§
Sourcefn handle_auction_component<'life0, 'async_trait>(
&'life0 self,
request: ComponentAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ComponentAuctionAck>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_auction_component<'life0, 'async_trait>(
&'life0 self,
request: ComponentAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ComponentAuctionAck>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle an auction request for a component. This method should return Ok(None) if the host
does not want to respond to the auction request.
Sourcefn handle_auction_provider<'life0, 'async_trait>(
&'life0 self,
request: ProviderAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ProviderAuctionAck>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_auction_provider<'life0, 'async_trait>(
&'life0 self,
request: ProviderAuctionRequest,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<ProviderAuctionAck>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle an auction request for a provider. This method should return Ok(None) if the host
does not want to respond to the auction request.
Sourcefn handle_stop_host<'life0, 'async_trait>(
&'life0 self,
request: StopHostCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_stop_host<'life0, 'async_trait>(
&'life0 self,
request: StopHostCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to stop the host. This method should return a response indicating success or failure.
Sourcefn handle_scale_component<'async_trait>(
self: Arc<Self>,
request: ScaleComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
fn handle_scale_component<'async_trait>(
self: Arc<Self>,
request: ScaleComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
Handle a request to scale a component. This method should return a response indicating success or failure.
Sourcefn handle_update_component<'async_trait>(
self: Arc<Self>,
request: UpdateComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
fn handle_update_component<'async_trait>(
self: Arc<Self>,
request: UpdateComponentCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
Handle a request to update a component. This method should return a response indicating success or failure.
Sourcefn handle_start_provider<'async_trait>(
self: Arc<Self>,
request: StartProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<()>>>> + Send + 'async_trait>>where
Self: 'async_trait,
fn handle_start_provider<'async_trait>(
self: Arc<Self>,
request: StartProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<Option<CtlResponse<()>>>> + Send + 'async_trait>>where
Self: 'async_trait,
Handle a request to start a provider. This method should return a response indicating success or failure.
Sourcefn handle_stop_provider<'life0, 'async_trait>(
&'life0 self,
request: StopProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_stop_provider<'life0, 'async_trait>(
&'life0 self,
request: StopProviderCommand,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to stop a provider. This method should return a response indicating success or failure.
Sourcefn handle_inventory<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<HostInventory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_inventory<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<HostInventory>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to get the host inventory. This method should return a response containing the host inventory.
Sourcefn handle_claims<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Vec<HashMap<String, String>>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_claims<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Vec<HashMap<String, String>>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to get the claims for all components and providers. This method should return a response containing the claims.
Sourcefn handle_links<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_links<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to get the links for all components. This method should return a response containing the links.
Sourcefn handle_config_get<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn handle_config_get<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Vec<u8>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Handle a request to get the configuration for a specific key. This method should return a response containing the configuration.
Sourcefn handle_config_delete<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn handle_config_delete<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Handle a request to delete the configuration for a specific key. This method should return a response indicating success or failure.
Sourcefn handle_label_put<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabel,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn handle_label_put<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabel,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Handle a request to put a label on the host. This method should return a response indicating success or failure.
Sourcefn handle_label_del<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabelIdentifier,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn handle_label_del<'life0, 'life1, 'async_trait>(
&'life0 self,
request: HostLabelIdentifier,
host_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Handle a request to delete a label from the host. This method should return a response indicating success or failure.
Sourcefn handle_link_put<'life0, 'async_trait>(
&'life0 self,
request: Link,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_link_put<'life0, 'async_trait>(
&'life0 self,
request: Link,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to put a link on a component. This method should return a response indicating success or failure.
Sourcefn handle_link_del<'life0, 'async_trait>(
&'life0 self,
request: DeleteInterfaceLinkDefinitionRequest,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_link_del<'life0, 'async_trait>(
&'life0 self,
request: DeleteInterfaceLinkDefinitionRequest,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to delete a link from a component. This method should return a response indicating success or failure.
Sourcefn handle_registries_put<'life0, 'async_trait>(
&'life0 self,
request: HashMap<String, RegistryCredential>,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_registries_put<'life0, 'async_trait>(
&'life0 self,
request: HashMap<String, RegistryCredential>,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to put registry credentials. This method should return a response indicating success or failure.
Sourcefn handle_config_put<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
data: Bytes,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn handle_config_put<'life0, 'life1, 'async_trait>(
&'life0 self,
config_name: &'life1 str,
data: Bytes,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<()>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Handle a request to put configuration data. This method should return a response indicating success or failure.
Sourcefn handle_ping_hosts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Host>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle_ping_hosts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<CtlResponse<Host>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a request to ping all hosts in the lattice. This method should return a response containing the host data.