2020-11-29 18:50:51 +00:00
|
|
|
use thiserror::Error;
|
|
|
|
|
|
|
|
#[derive (Debug, Error)]
|
|
|
|
pub enum ServerError {
|
2020-11-29 19:19:59 +00:00
|
|
|
#[error ("File server error")]
|
|
|
|
FileServer (#[from] super::file_server::errors::FileServerError),
|
2020-11-29 18:50:51 +00:00
|
|
|
|
2020-11-29 19:19:59 +00:00
|
|
|
#[error ("Hyper HTTP error")]
|
|
|
|
Http (#[from] hyper::http::Error),
|
|
|
|
|
|
|
|
#[error ("Hyper invalid header name")]
|
|
|
|
InvalidHeaderName (#[from] hyper::header::InvalidHeaderName),
|
|
|
|
|
|
|
|
#[error ("Can't parse wrapped requests")]
|
|
|
|
CantParseWrappedRequests (rmp_serde::decode::Error),
|
2020-11-29 18:50:51 +00:00
|
|
|
}
|