summaryrefslogtreecommitdiff
path: root/rola-bucket/src/protocol
diff options
context:
space:
mode:
Diffstat (limited to 'rola-bucket/src/protocol')
-rw-r--r--rola-bucket/src/protocol/error.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/rola-bucket/src/protocol/error.rs b/rola-bucket/src/protocol/error.rs
new file mode 100644
index 0000000..95447f7
--- /dev/null
+++ b/rola-bucket/src/protocol/error.rs
@@ -0,0 +1,19 @@
+use thiserror::Error;
+
+#[derive(Error, Debug)]
+pub enum BucketTransferProtocolError {
+ #[error("network connection failed: {0}")]
+ NetworkError(#[source] std::io::Error),
+
+ #[error("authentication failed: {0}")]
+ AuthenticationError(String),
+
+ #[error("permission denied: {0}")]
+ PermissionDenied(String),
+
+ #[error("I/O error: {0}")]
+ IoError(#[source] std::io::Error),
+
+ #[error("timeout occurred")]
+ Timeout,
+}