mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-03 11:57:07 +02:00
improve the count of the number of tasks in a batch
This commit is contained in:
parent
71807cac6d
commit
1e694ae432
2 changed files with 8 additions and 3 deletions
|
@ -61,9 +61,9 @@ impl ProcessingBatch {
|
|||
|
||||
/// Update itself with the content of the task and update the batch id in the task.
|
||||
pub fn processing<'a>(&mut self, tasks: impl IntoIterator<Item = &'a mut Task>) {
|
||||
self.stats.total_nb_tasks += 1;
|
||||
|
||||
for task in tasks.into_iter() {
|
||||
self.stats.total_nb_tasks += 1;
|
||||
|
||||
task.batch_uid = Some(self.uid);
|
||||
// We don't store the statuses in the map since they're all enqueued but we must
|
||||
// still store them in the stats since that can be displayed.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue