diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index ce86c10ca..fc6fb194c 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -496,8 +496,7 @@ impl IndexScheduler { // 5. We make a batch from the unprioritised tasks. Start by taking the next enqueued task. let task_id = if let Some(task_id) = enqueued.min() { task_id } else { return Ok(None) }; - let mut task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; - current_batch.processing(Some(&mut task)); + let task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; // If the task is not associated with any index, verify that it is an index swap and // create the batch directly. Otherwise, get the index name associated with the task diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 2d953fc6e..9715e9e2f 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -4333,15 +4333,15 @@ mod tests { "primaryKey": "mouse" }, "stats": { - "totalNbTasks": 2, + "totalNbTasks": 1, "status": { - "processing": 2 + "processing": 1 }, "types": { - "indexCreation": 2 + "indexCreation": 1 }, "indexUids": { - "catto": 2 + "catto": 1 } }, "startedAt": "1970-01-01T00:00:00Z",