pub enum Error<S, B> {
KeepAliveExpire,
RequestTimeout,
Closed,
Service(S),
Body(B),
Io(Error),
Proto(ProtoError),
}
Variants§
KeepAliveExpire
socket keep-alive timer expired.
RequestTimeout
socket fail to receive a complete request head in given time window.
Closed
Service(S)
service error. terminate connection right away.
Body(B)
service response body error. terminate connection right away.
Io(Error)
socket and/or runtime error. terminate connection right away.
Proto(ProtoError)
http/1 protocol error. transform into http response and send to client. after which the connection can be gracefully shutdown or kept open.
Trait Implementations§
Source§impl<S, B> From<Error<S, B>> for HttpServiceError<S, B>
impl<S, B> From<Error<S, B>> for HttpServiceError<S, B>
Source§impl<S, B> From<ProtoError> for Error<S, B>
impl<S, B> From<ProtoError> for Error<S, B>
Source§fn from(e: ProtoError) -> Self
fn from(e: ProtoError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<S, B> Freeze for Error<S, B>
impl<S, B> !RefUnwindSafe for Error<S, B>
impl<S, B> Send for Error<S, B>
impl<S, B> Sync for Error<S, B>
impl<S, B> Unpin for Error<S, B>
impl<S, B> !UnwindSafe for Error<S, B>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more