diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/api/Cargo.toml | 2 | ||||
-rw-r--r-- | src/db/test.rs | 13 | ||||
-rw-r--r-- | src/garage/Cargo.toml | 2 | ||||
-rw-r--r-- | src/k2v-client/Cargo.toml | 2 | ||||
-rw-r--r-- | src/rpc/Cargo.toml | 7 | ||||
-rw-r--r-- | src/web/web_server.rs | 2 |
6 files changed, 16 insertions, 12 deletions
diff --git a/src/api/Cargo.toml b/src/api/Cargo.toml index 7c3ed43b..4d9a6ab6 100644 --- a/src/api/Cargo.toml +++ b/src/api/Cargo.toml @@ -36,7 +36,7 @@ sha2 = "0.10" futures = "0.3" futures-util = "0.3" -pin-project = "1.0" +pin-project = "1.0.11" tokio = { version = "1.0", default-features = false, features = ["rt", "rt-multi-thread", "io-util", "net", "time", "macros", "sync", "signal", "fs"] } tokio-stream = "0.1" diff --git a/src/db/test.rs b/src/db/test.rs index cfcee643..40e6c41e 100644 --- a/src/db/test.rs +++ b/src/db/test.rs @@ -1,9 +1,5 @@ use crate::*; -use crate::lmdb_adapter::LmdbDb; -use crate::sled_adapter::SledDb; -use crate::sqlite_adapter::SqliteDb; - fn test_suite(db: Db) { let tree = db.open_tree("tree").unwrap(); @@ -80,7 +76,10 @@ fn test_suite(db: Db) { } #[test] +#[cfg(feature = "lmdb")] fn test_lmdb_db() { + use crate::lmdb_adapter::LmdbDb; + let path = mktemp::Temp::new_dir().unwrap(); let db = heed::EnvOpenOptions::new() .max_dbs(100) @@ -92,7 +91,10 @@ fn test_lmdb_db() { } #[test] +#[cfg(feature = "sled")] fn test_sled_db() { + use crate::sled_adapter::SledDb; + let path = mktemp::Temp::new_dir().unwrap(); let db = SledDb::init(sled::open(path.to_path_buf()).unwrap()); test_suite(db); @@ -100,7 +102,10 @@ fn test_sled_db() { } #[test] +#[cfg(feature = "sqlite")] fn test_sqlite_db() { + use crate::sqlite_adapter::SqliteDb; + let db = SqliteDb::init(rusqlite::Connection::open_in_memory().unwrap()); test_suite(db); } diff --git a/src/garage/Cargo.toml b/src/garage/Cargo.toml index 5ce40ff2..ddc23170 100644 --- a/src/garage/Cargo.toml +++ b/src/garage/Cargo.toml @@ -58,7 +58,7 @@ opentelemetry-otlp = { version = "0.10", optional = true } prometheus = { version = "0.13", optional = true } [dev-dependencies] -aws-sdk-s3 = "0.8" +aws-sdk-s3 = "0.19" chrono = "0.4" http = "0.2" hmac = "0.12" diff --git a/src/k2v-client/Cargo.toml b/src/k2v-client/Cargo.toml index 0f0b76ae..9d2b4e30 100644 --- a/src/k2v-client/Cargo.toml +++ b/src/k2v-client/Cargo.toml @@ -12,7 +12,7 @@ readme = "../../README.md" base64 = "0.13.0" http = "0.2.6" log = "0.4" -rusoto_core = "0.48.0" +rusoto_core = { version = "0.48.0", default-features = false, features = ["rustls"] } rusoto_credential = "0.48.0" rusoto_signature = "0.48.0" serde = "1.0.137" diff --git a/src/rpc/Cargo.toml b/src/rpc/Cargo.toml index d61acea4..883929e8 100644 --- a/src/rpc/Cargo.toml +++ b/src/rpc/Cargo.toml @@ -31,9 +31,8 @@ serde_bytes = "0.11" serde_json = "1.0" # newer version requires rust edition 2021 -kube = { version = "0.62", features = ["runtime", "derive"], optional = true } -k8s-openapi = { version = "0.13", features = ["v1_22"], optional = true } -openssl = { version = "0.10", features = ["vendored"], optional = true } +kube = { version = "0.75", default-features = false, features = ["runtime", "derive", "client", "rustls-tls"], optional = true } +k8s-openapi = { version = "0.16", features = ["v1_22"], optional = true } schemars = { version = "0.8", optional = true } # newer version requires rust edition 2021 @@ -51,5 +50,5 @@ hyper = { version = "0.14", features = ["client", "http1", "runtime", "tcp"] } [features] -kubernetes-discovery = [ "kube", "k8s-openapi", "openssl", "schemars" ] +kubernetes-discovery = [ "kube", "k8s-openapi", "schemars" ] system-libs = [ "sodiumoxide/use-pkg-config" ] diff --git a/src/web/web_server.rs b/src/web/web_server.rs index c2322073..1541c297 100644 --- a/src/web/web_server.rs +++ b/src/web/web_server.rs @@ -318,7 +318,7 @@ fn path_to_key<'a>(path: &'a str, index: &str) -> Result<Cow<'a, str>, Error> { } Some(_) => match path_utf8 { Cow::Borrowed(pu8) => Ok((&pu8[1..]).into()), - Cow::Owned(pu8) => Ok((&pu8[1..]).to_string().into()), + Cow::Owned(pu8) => Ok(pu8[1..].to_string().into()), }, } } |