Issue 762 (#763)

* Add InvalidRangeSpec error

* Add EntityTooSmall to from_u32

* Add InvalidRangeSpec to from_u32

* Map InvalidRangeSpec to correct S3ErrorCode

* Return Error::InvalidRangeSpec

* Use auto implementation

---------

Co-authored-by: Niklas Mollenhauer <nikeee@outlook.com>
This commit is contained in:
loverustfs
2025-10-31 17:20:18 +08:00
committed by GitHub
parent f0c2ede7a7
commit 325ff62684
7 changed files with 23 additions and 36 deletions
+2 -8
View File
@@ -21,21 +21,15 @@ use std::time::Duration;
use url::Url;
/// KMS backend types
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, Eq)]
#[derive(Debug, Default, Clone, Serialize, Deserialize, PartialEq, Eq)]
pub enum KmsBackend {
/// Vault backend (recommended for production)
Vault,
/// Local file-based backend for development and testing only
#[default]
Local,
}
impl Default for KmsBackend {
fn default() -> Self {
// Default to Local backend since Vault requires configuration
Self::Local
}
}
/// Main KMS configuration
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct KmsConfig {