pub trait RemoteDispatchHandler: Send + Sync {
// Required method
fn dispatch<'life0, 'async_trait>(
&'life0 self,
request: RemoteDispatch,
) -> Pin<Box<dyn Future<Output = Result<RemoteDispatchAction, Error>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
}Expand description
Transport-agnostic publisher for runtime dispatch requests. Implemented over
raw async-nats today; the trait lets a greentic-events EventBus be swapped
in later without changing the flow engine.
Required Methods§
fn dispatch<'life0, 'async_trait>(
&'life0 self,
request: RemoteDispatch,
) -> Pin<Box<dyn Future<Output = Result<RemoteDispatchAction, Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".