mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-05 20:48:58 +01:00
Merge #2724
2724: Make the document addition done log to appear once indexing is over r=curquiza a=evpeople # Pull Request ## What does this PR do? Fixes #2703 <!-- Please link the issue you're trying to fix with this PR, if none then please create an issue first. --> ## PR checklist Please check if your PR fulfills the following requirements: - [x] Does this PR fix an existing issue? - [x] Have you read the contributing guidelines? - [x] Have you made sure that the title is accurate and descriptive of the changes? Thank you so much for contributing to Meilisearch! Co-authored-by: evpeople <hangcaihui@gmail.com>
This commit is contained in:
commit
e315547ffc
670
Cargo.lock
generated
670
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -331,14 +331,10 @@ impl Index {
|
|||||||
builder = new_builder;
|
builder = new_builder;
|
||||||
|
|
||||||
let user_result = match user_result {
|
let user_result = match user_result {
|
||||||
Ok(count) => {
|
Ok(count) => Ok(DocumentAdditionResult {
|
||||||
let addition = DocumentAdditionResult {
|
|
||||||
indexed_documents: count,
|
indexed_documents: count,
|
||||||
number_of_documents: count,
|
number_of_documents: count,
|
||||||
};
|
}),
|
||||||
info!("document addition done: {:?}", addition);
|
|
||||||
Ok(addition)
|
|
||||||
}
|
|
||||||
Err(e) => Err(IndexError::from(e)),
|
Err(e) => Err(IndexError::from(e)),
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -346,8 +342,9 @@ impl Index {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if results.iter().any(Result::is_ok) {
|
if results.iter().any(Result::is_ok) {
|
||||||
let _addition = builder.execute()?;
|
let addition = builder.execute()?;
|
||||||
txn.commit()?;
|
txn.commit()?;
|
||||||
|
info!("document addition done: {:?}", addition);
|
||||||
}
|
}
|
||||||
|
|
||||||
Ok(results)
|
Ok(results)
|
||||||
|
Loading…
Reference in New Issue
Block a user