mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-23 05:14:27 +01:00
Remove the docid_word_positions_merge method that must never be called
This commit is contained in:
parent
93a8633f18
commit
ab727e428b
@ -18,10 +18,6 @@ pub fn fst_merge(_key: &[u8], values: &[Cow<[u8]>]) -> anyhow::Result<Vec<u8>> {
|
|||||||
Ok(build.into_inner().unwrap())
|
Ok(build.into_inner().unwrap())
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn docid_word_positions_merge(key: &[u8], _values: &[Cow<[u8]>]) -> anyhow::Result<Vec<u8>> {
|
|
||||||
panic!("merging docid word positions is an error ({:?})", key.as_bstr())
|
|
||||||
}
|
|
||||||
|
|
||||||
pub fn keep_first(_key: &[u8], values: &[Cow<[u8]>]) -> anyhow::Result<Vec<u8>> {
|
pub fn keep_first(_key: &[u8], values: &[Cow<[u8]>]) -> anyhow::Result<Vec<u8>> {
|
||||||
Ok(values.first().unwrap().to_vec())
|
Ok(values.first().unwrap().to_vec())
|
||||||
}
|
}
|
||||||
|
@ -25,8 +25,7 @@ use crate::update::{
|
|||||||
};
|
};
|
||||||
use self::store::{Store, Readers};
|
use self::store::{Store, Readers};
|
||||||
pub use self::merge_function::{
|
pub use self::merge_function::{
|
||||||
fst_merge, cbo_roaring_bitmap_merge, roaring_bitmap_merge,
|
fst_merge, cbo_roaring_bitmap_merge, roaring_bitmap_merge, keep_first
|
||||||
docid_word_positions_merge, keep_first
|
|
||||||
};
|
};
|
||||||
pub use self::transform::{Transform, TransformOutput};
|
pub use self::transform::{Transform, TransformOutput};
|
||||||
|
|
||||||
@ -619,12 +618,12 @@ impl<'t, 'u, 'i, 'a> IndexDocuments<'t, 'u, 'i, 'a> {
|
|||||||
total_databases,
|
total_databases,
|
||||||
});
|
});
|
||||||
|
|
||||||
debug!("Writing the docid word positions into LMDB on disk...");
|
debug!("Inserting the docid word positions into LMDB on disk...");
|
||||||
merge_into_lmdb_database(
|
merge_into_lmdb_database(
|
||||||
self.wtxn,
|
self.wtxn,
|
||||||
*self.index.docid_word_positions.as_polymorph(),
|
*self.index.docid_word_positions.as_polymorph(),
|
||||||
docid_word_positions_readers,
|
docid_word_positions_readers,
|
||||||
docid_word_positions_merge,
|
keep_first,
|
||||||
write_method
|
write_method
|
||||||
)?;
|
)?;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user