From b22f1260bfbe86285d45bde6c8533aedcb75f119 Mon Sep 17 00:00:00 2001 From: Tamo Date: Fri, 13 Oct 2023 11:04:12 +0200 Subject: [PATCH] bump strois to a temporary version while we wait for rusty_s3 to do a new release --- Cargo.lock | 6 ++---- Cargo.toml | 3 +++ meilisearch/src/lib.rs | 5 +++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5bca17310..a6f84831d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3707,8 +3707,7 @@ checksum = "4f3208ce4d8448b3f3e7d168a73f5e0c43a61e32930de3bceeccedb388b6bf06" [[package]] name = "rusty-s3" version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31aa883f1b986a5249641e574ca0e11ac4fb9970b009c6fbb96fedaf4fa78db8" +source = "git+https://github.com/irevoire/rusty-s3?rev=b4d73a8#b4d73a83545fd6a6d211cc2b56eb8ed7bb248a62" dependencies = [ "base64 0.21.2", "hmac", @@ -4010,8 +4009,7 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "strois" version = "0.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dde87abcdf0638bf1e0e762e5f4466f68aa9862bc061093f3914641f9db26f6" +source = "git+http://github.com/meilisearch/strois?rev=7f6832a#7f6832ae701a5414b58441220e2a028c46bdb9ab" dependencies = [ "http", "log", diff --git a/Cargo.toml b/Cargo.toml index 4f6546f03..50dfbb2db 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -36,3 +36,6 @@ opt-level = 3 opt-level = 3 [profile.dev.package.roaring] opt-level = 3 + +[patch.crates-io] +strois = { git = "http://github.com/meilisearch/strois", rev = "7f6832a" } diff --git a/meilisearch/src/lib.rs b/meilisearch/src/lib.rs index b5e158dde..9d9611bfd 100644 --- a/meilisearch/src/lib.rs +++ b/meilisearch/src/lib.rs @@ -39,7 +39,7 @@ use meilisearch_types::versioning::{check_version_file, create_version_file}; use meilisearch_types::{compression, milli, VERSION_FILE_NAME}; pub use option::Opt; use option::ScheduleSnapshot; -use strois::Client; +use strois::Bucket; use zookeeper::ZooKeeper; use crate::error::MeilisearchHttpError; @@ -245,12 +245,13 @@ fn open_or_create_database_unchecked( zookeeper: zookeeper.clone(), s3: opt.s3_url.as_ref().map(|url| { Arc::new( - Client::builder(url) + Bucket::builder(url) .unwrap() .key(opt.s3_access_key.as_ref().expect("Need s3 key to work").clone()) .secret(opt.s3_secret_key.as_ref().expect("Need s3 secret to work").clone()) .maybe_token(opt.s3_security_token.clone()) .region(&opt.s3_region) + .with_url_path_style(true) .bucket(opt.s3_bucket.as_ref().expect("Need an s3 bucket to work")) .unwrap() .get_or_create()