pub trait Service: Send + Sync {
type Error: Error + Send + Sync + 'static;
// Required method
fn run<'async_trait>(
self,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>
where Self: 'async_trait;
}Expand description
A service that handles a specific type of connection
Services are created by a ServiceRouter and run independently
to handle bi-directional streams from authenticated clients.