diff --git a/meilidb-core/Cargo.toml b/meilidb-core/Cargo.toml index b9f0deaa7..35f31468d 100644 --- a/meilidb-core/Cargo.toml +++ b/meilidb-core/Cargo.toml @@ -12,7 +12,7 @@ crossbeam-channel = "0.3.9" deunicode = "1.0.0" env_logger = "0.7.0" hashbrown = { version = "0.6.0", features = ["serde"] } -heed = "0.1.0" +heed = "0.3.0" log = "0.4.8" meilidb-schema = { path = "../meilidb-schema", version = "0.6.0" } meilidb-tokenizer = { path = "../meilidb-tokenizer", version = "0.6.0" } diff --git a/meilidb-core/src/database.rs b/meilidb-core/src/database.rs index 416b806a4..fa5b6bfde 100644 --- a/meilidb-core/src/database.rs +++ b/meilidb-core/src/database.rs @@ -72,7 +72,7 @@ impl Database { .max_dbs(3000) .open(path)?; - let common_store = env.create_dyn_database(Some("common"))?; + let common_store = env.create_poly_database(Some("common"))?; let indexes_store = env.create_database::(Some("indexes"))?; // list all indexes that needs to be opened diff --git a/meilidb-core/src/store/documents_fields.rs b/meilidb-core/src/store/documents_fields.rs index f4c218501..f63a5fa1c 100644 --- a/meilidb-core/src/store/documents_fields.rs +++ b/meilidb-core/src/store/documents_fields.rs @@ -29,7 +29,7 @@ impl DocumentsFields { ) -> ZResult { let start = DocumentAttrKey::new(document_id, SchemaAttr::min()); let end = DocumentAttrKey::new(document_id, SchemaAttr::max()); - self.documents_fields.delete_range(writer, start..=end) + self.documents_fields.delete_range(writer, &(start..=end)) } pub fn clear(self, writer: &mut heed::RwTxn) -> ZResult<()> { @@ -53,7 +53,7 @@ impl DocumentsFields { ) -> ZResult> { let start = DocumentAttrKey::new(document_id, SchemaAttr::min()); let end = DocumentAttrKey::new(document_id, SchemaAttr::max()); - let iter = self.documents_fields.range(reader, start..=end)?; + let iter = self.documents_fields.range(reader, &(start..=end))?; Ok(DocumentFieldsIter { iter }) } } diff --git a/meilidb-core/src/store/documents_fields_counts.rs b/meilidb-core/src/store/documents_fields_counts.rs index 2070cff6e..67c28682b 100644 --- a/meilidb-core/src/store/documents_fields_counts.rs +++ b/meilidb-core/src/store/documents_fields_counts.rs @@ -29,7 +29,7 @@ impl DocumentsFieldsCounts { let start = DocumentAttrKey::new(document_id, SchemaAttr::min()); let end = DocumentAttrKey::new(document_id, SchemaAttr::max()); self.documents_fields_counts - .delete_range(writer, start..=end) + .delete_range(writer, &(start..=end)) } pub fn clear(self, writer: &mut heed::RwTxn) -> ZResult<()> { @@ -56,7 +56,7 @@ impl DocumentsFieldsCounts { ) -> ZResult> { let start = DocumentAttrKey::new(document_id, SchemaAttr::min()); let end = DocumentAttrKey::new(document_id, SchemaAttr::max()); - let iter = self.documents_fields_counts.range(reader, start..=end)?; + let iter = self.documents_fields_counts.range(reader, &(start..=end))?; Ok(DocumentFieldsCountsIter { iter }) } diff --git a/meilidb-core/src/store/mod.rs b/meilidb-core/src/store/mod.rs index a8ea439ed..72317e202 100644 --- a/meilidb-core/src/store/mod.rs +++ b/meilidb-core/src/store/mod.rs @@ -283,7 +283,7 @@ pub fn create( let updates_results_name = updates_results_name(name); // open all the stores - let main = env.create_dyn_database(Some(&main_name))?; + let main = env.create_poly_database(Some(&main_name))?; let postings_lists = env.create_database(Some(&postings_lists_name))?; let documents_fields = env.create_database(Some(&documents_fields_name))?; let documents_fields_counts = env.create_database(Some(&documents_fields_counts_name))?; @@ -323,7 +323,7 @@ pub fn open( let updates_results_name = updates_results_name(name); // open all the stores - let main = match env.open_dyn_database(Some(&main_name))? { + let main = match env.open_poly_database(Some(&main_name))? { Some(main) => main, None => return Ok(None), }; diff --git a/meilidb-http/Cargo.toml b/meilidb-http/Cargo.toml index 890c8aec8..12c1a5fc6 100644 --- a/meilidb-http/Cargo.toml +++ b/meilidb-http/Cargo.toml @@ -13,7 +13,7 @@ chrono = { version = "0.4.9", features = ["serde"] } crossbeam-channel = "0.3.9" envconfig = "0.5.1" envconfig_derive = "0.5.1" -heed = "0.1.0" +heed = "0.3.0" http = "0.1.19" indexmap = { version = "1.3.0", features = ["serde-1"] } jemallocator = "0.3.2"