Trait salvo_core::tower_compat::TowerLayerCompat
source · pub trait TowerLayerCompat {
// Provided method
fn compat<QB>(self) -> TowerLayerHandler<Self::Service, QB>
where QB: TryFrom<ReqBody> + Body + Send + Sync + 'static,
<QB as TryFrom<ReqBody>>::Error: StdError + Send + Sync + 'static,
Self: Layer<FlowCtrlService> + Sized,
Self::Service: Service<Request<QB>> + Sync + Send + 'static,
<Self::Service as Service<Request<QB>>>::Future: Send,
<Self::Service as Service<Request<QB>>>::Error: StdError + Send + Sync { ... }
}
Available on crate feature
tower-compat
only.Expand description
Trait for tower layer compat.
Provided Methods§
sourcefn compat<QB>(self) -> TowerLayerHandler<Self::Service, QB>where
QB: TryFrom<ReqBody> + Body + Send + Sync + 'static,
<QB as TryFrom<ReqBody>>::Error: StdError + Send + Sync + 'static,
Self: Layer<FlowCtrlService> + Sized,
Self::Service: Service<Request<QB>> + Sync + Send + 'static,
<Self::Service as Service<Request<QB>>>::Future: Send,
<Self::Service as Service<Request<QB>>>::Error: StdError + Send + Sync,
fn compat<QB>(self) -> TowerLayerHandler<Self::Service, QB>where
QB: TryFrom<ReqBody> + Body + Send + Sync + 'static,
<QB as TryFrom<ReqBody>>::Error: StdError + Send + Sync + 'static,
Self: Layer<FlowCtrlService> + Sized,
Self::Service: Service<Request<QB>> + Sync + Send + 'static,
<Self::Service as Service<Request<QB>>>::Future: Send,
<Self::Service as Service<Request<QB>>>::Error: StdError + Send + Sync,
Converts a tower layer to a salvo handler.