aboutsummaryrefslogtreecommitdiff
path: root/src/error.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2020-04-08 00:39:07 +0200
committerAlex Auvolat <alex@adnab.me>2020-04-08 00:39:07 +0200
commitd50edcdb4f8b8ec00b1f0ffb6a3ebbb0e5afdc1f (patch)
treeb283abf578b3c80c2885eb0e220f7f3a02ba994d /src/error.rs
parent90cdffb425c6222f4234db54a16c079d8c058724 (diff)
downloadgarage-d50edcdb4f8b8ec00b1f0ffb6a3ebbb0e5afdc1f.tar.gz
garage-d50edcdb4f8b8ec00b1f0ffb6a3ebbb0e5afdc1f.zip
Basic workflow for client PUT, next is do actual storage
Diffstat (limited to 'src/error.rs')
-rw-r--r--src/error.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/error.rs b/src/error.rs
index fd717638..30f7dac6 100644
--- a/src/error.rs
+++ b/src/error.rs
@@ -12,6 +12,9 @@ pub enum Error {
#[error(display = "HTTP error: {}", _0)]
HTTP(#[error(source)] http::Error),
+ #[error(display = "Invalid HTTP header value: {}", _0)]
+ HTTPHeader(#[error(source)] http::header::ToStrError),
+
#[error(display = "Messagepack encode error: {}", _0)]
RMPEncode(#[error(source)] rmp_serde::encode::Error),
#[error(display = "Messagepack decode error: {}", _0)]
@@ -27,5 +30,8 @@ pub enum Error {
RPCError(String),
#[error(display = "{}", _0)]
+ BadRequest(String),
+
+ #[error(display = "{}", _0)]
Message(String),
}