mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-05 12:38:55 +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;
|
||||
|
||||
let user_result = match user_result {
|
||||
Ok(count) => {
|
||||
let addition = DocumentAdditionResult {
|
||||
indexed_documents: count,
|
||||
number_of_documents: count,
|
||||
};
|
||||
info!("document addition done: {:?}", addition);
|
||||
Ok(addition)
|
||||
}
|
||||
Ok(count) => Ok(DocumentAdditionResult {
|
||||
indexed_documents: count,
|
||||
number_of_documents: count,
|
||||
}),
|
||||
Err(e) => Err(IndexError::from(e)),
|
||||
};
|
||||
|
||||
@ -346,8 +342,9 @@ impl Index {
|
||||
}
|
||||
|
||||
if results.iter().any(Result::is_ok) {
|
||||
let _addition = builder.execute()?;
|
||||
let addition = builder.execute()?;
|
||||
txn.commit()?;
|
||||
info!("document addition done: {:?}", addition);
|
||||
}
|
||||
|
||||
Ok(results)
|
||||
|
Loading…
Reference in New Issue
Block a user