mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-01-22 19:13:10 +08:00
Merge #5242
Some checks failed
Test suite / Tests on ubuntu-20.04 (push) Failing after 13s
Test suite / Tests almost all features (push) Has been skipped
Test suite / Test disabled tokenization (push) Has been skipped
Test suite / Tests on ${{ matrix.os }} (windows-2022) (push) Failing after 14s
Test suite / Run tests in debug (push) Failing after 11s
Test suite / Run Clippy (push) Successful in 7m16s
Test suite / Run Rustfmt (push) Successful in 2m41s
Test suite / Tests on ${{ matrix.os }} (macos-13) (push) Has been cancelled
Some checks failed
Test suite / Tests on ubuntu-20.04 (push) Failing after 13s
Test suite / Tests almost all features (push) Has been skipped
Test suite / Test disabled tokenization (push) Has been skipped
Test suite / Tests on ${{ matrix.os }} (windows-2022) (push) Failing after 14s
Test suite / Run tests in debug (push) Failing after 11s
Test suite / Run Clippy (push) Successful in 7m16s
Test suite / Run Rustfmt (push) Successful in 2m41s
Test suite / Tests on ${{ matrix.os }} (macos-13) (push) Has been cancelled
5242: Fix infinite loop r=Kerollmops a=dureuill - Fix possible infinite loop by releasing `writer_receiver` as soon as writing to DB panics - Demote panic to error log Co-authored-by: Louis Dureuil <louis@meilisearch.com>
This commit is contained in:
commit
a5c44b4d79
@ -110,7 +110,7 @@ where
|
|||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
let (extractor_sender, mut writer_receiver) = pool
|
let (extractor_sender, writer_receiver) = pool
|
||||||
.install(|| extractor_writer_bbqueue(&mut bbbuffers, total_bbbuffer_capacity, 1000))
|
.install(|| extractor_writer_bbqueue(&mut bbbuffers, total_bbbuffer_capacity, 1000))
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
|
||||||
@ -425,6 +425,7 @@ where
|
|||||||
let mut arroy_writers = arroy_writers?;
|
let mut arroy_writers = arroy_writers?;
|
||||||
|
|
||||||
{
|
{
|
||||||
|
let mut writer_receiver = writer_receiver;
|
||||||
let span = tracing::trace_span!(target: "indexing::write_db", "all");
|
let span = tracing::trace_span!(target: "indexing::write_db", "all");
|
||||||
let _entered = span.enter();
|
let _entered = span.enter();
|
||||||
|
|
||||||
@ -584,10 +585,12 @@ fn write_from_bbqueue(
|
|||||||
}
|
}
|
||||||
(key, None) => match database.delete(wtxn, key) {
|
(key, None) => match database.delete(wtxn, key) {
|
||||||
Ok(false) => {
|
Ok(false) => {
|
||||||
unreachable!(
|
tracing::error!(
|
||||||
"We tried to delete an unknown key from {database_name}: {:?}",
|
database_name,
|
||||||
key.as_bstr()
|
key_bytes = ?key,
|
||||||
)
|
formatted_key = ?key.as_bstr(),
|
||||||
|
"Attempt to delete an unknown key"
|
||||||
|
);
|
||||||
}
|
}
|
||||||
Ok(_) => (),
|
Ok(_) => (),
|
||||||
Err(error) => {
|
Err(error) => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user