Reintroduce the distinct search system

This commit is contained in:
Clément Renault
2020-01-16 15:55:55 +01:00
parent 74fa9ee4df
commit 96139da0d2
6 changed files with 275 additions and 565 deletions

View File

@ -9,7 +9,6 @@ use fst::{IntoStreamer, Streamer};
use itertools::{EitherOrBoth, merge_join_by};
use meilisearch_tokenizer::split_query_string;
use sdset::{Set, SetBuf, SetOperation};
use slice_group_by::StrGroupBy;
use crate::database::MainT;
use crate::{store, DocumentId, DocIndex, MResult};
@ -387,7 +386,7 @@ pub fn traverse_query_tree<'o, 'txn>(
{
let before = Instant::now();
let Query { id, prefix, kind } = query;
let Query { prefix, kind, .. } = query;
let docids: Cow<Set<_>> = match kind {
QueryKind::Tolerant(word) => {
if *prefix && word.len() <= 2 {