Release writer_receiver as soon as writing to db panics

This commit is contained in:
Louis Dureuil 2025-01-16 11:37:37 +01:00
parent aee74f47aa
commit ce621e447e
No known key found for this signature in database

View File

@ -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();