From ee6be4f6b96fd0ec42f3248c511eabdc70e81c5b Mon Sep 17 00:00:00 2001 From: Kerollmops Date: Thu, 24 Mar 2022 14:44:52 +0100 Subject: [PATCH] Import milli from meilisearch-lib in meilisearch-http --- Cargo.lock | 1 - meilisearch-http/Cargo.toml | 1 - meilisearch-http/src/helpers/env.rs | 3 ++- meilisearch-lib/src/lib.rs | 1 - 4 files changed, 2 insertions(+), 4 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 11becd56e..178cf7769 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1909,7 +1909,6 @@ dependencies = [ "meilisearch-auth", "meilisearch-error", "meilisearch-lib", - "milli", "mime", "num_cpus", "obkv", diff --git a/meilisearch-http/Cargo.toml b/meilisearch-http/Cargo.toml index 4a3b74b1f..546e414ce 100644 --- a/meilisearch-http/Cargo.toml +++ b/meilisearch-http/Cargo.toml @@ -47,7 +47,6 @@ log = "0.4.14" meilisearch-auth = { path = "../meilisearch-auth" } meilisearch-error = { path = "../meilisearch-error" } meilisearch-lib = { path = "../meilisearch-lib" } -milli = { git = "https://github.com/meilisearch/milli.git", tag = "v0.24.0" } mime = "0.3.16" num_cpus = "1.13.1" obkv = "0.2.0" diff --git a/meilisearch-http/src/helpers/env.rs b/meilisearch-http/src/helpers/env.rs index b36bdce0d..7c8237dad 100644 --- a/meilisearch-http/src/helpers/env.rs +++ b/meilisearch-http/src/helpers/env.rs @@ -1,10 +1,11 @@ +use meilisearch_lib::milli::heed::Env; use walkdir::WalkDir; pub trait EnvSizer { fn size(&self) -> u64; } -impl EnvSizer for milli::heed::Env { +impl EnvSizer for Env { fn size(&self) -> u64 { WalkDir::new(self.path()) .into_iter() diff --git a/meilisearch-lib/src/lib.rs b/meilisearch-lib/src/lib.rs index c49acfeee..b5bdd36c6 100644 --- a/meilisearch-lib/src/lib.rs +++ b/meilisearch-lib/src/lib.rs @@ -13,7 +13,6 @@ mod update_file_store; use std::path::Path; pub use index_controller::MeiliSearch; - pub use milli; mod compression;