From 60629146544a3a51fe12c0fdb19aea9a793eaec5 Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 13 Nov 2024 11:27:12 +0100 Subject: [PATCH 01/22] add the batch_id to the tasks --- crates/dump/src/lib.rs | 8 + crates/dump/src/reader/compat/v5_to_v6.rs | 1 + crates/index-scheduler/src/batch.rs | 106 ++++++--- crates/index-scheduler/src/error.rs | 10 +- crates/index-scheduler/src/insta_snapshot.rs | 16 ++ crates/index-scheduler/src/lib.rs | 204 +++++++++++++++++- crates/index-scheduler/src/utils.rs | 30 +++ crates/meilisearch-types/src/batches.rs | 18 ++ crates/meilisearch-types/src/error.rs | 1 + crates/meilisearch-types/src/lib.rs | 1 + crates/meilisearch-types/src/task_view.rs | 3 + crates/meilisearch-types/src/tasks.rs | 7 + crates/meilisearch/src/routes/batches.rs | 48 +++++ crates/meilisearch/src/routes/mod.rs | 1 + crates/meilisearch/src/routes/tasks.rs | 9 +- crates/meilisearch/tests/common/mod.rs | 1 + .../tests/documents/add_documents.rs | 35 +++ .../tests/documents/delete_documents.rs | 4 + crates/meilisearch/tests/documents/errors.rs | 3 + crates/meilisearch/tests/dumps/mod.rs | 24 +-- .../1.snap | 3 +- .../2.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/1.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/2.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/3.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/4.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/5.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/6.snap | 3 +- .../mod.rs/import_dump_v1_movie_raw/7.snap | 3 +- .../import_dump_v1_movie_with_settings/1.snap | 3 +- .../import_dump_v1_movie_with_settings/2.snap | 3 +- .../import_dump_v1_movie_with_settings/3.snap | 3 +- .../import_dump_v1_movie_with_settings/4.snap | 3 +- .../import_dump_v1_movie_with_settings/5.snap | 3 +- .../import_dump_v1_movie_with_settings/6.snap | 3 +- .../import_dump_v1_movie_with_settings/7.snap | 3 +- .../1.snap | 3 +- .../2.snap | 3 +- .../3.snap | 3 +- .../4.snap | 3 +- .../5.snap | 3 +- .../6.snap | 3 +- .../7.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/1.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/2.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/3.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/4.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/5.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/6.snap | 3 +- .../mod.rs/import_dump_v2_movie_raw/7.snap | 3 +- .../import_dump_v2_movie_with_settings/1.snap | 3 +- .../import_dump_v2_movie_with_settings/2.snap | 3 +- .../import_dump_v2_movie_with_settings/3.snap | 3 +- .../import_dump_v2_movie_with_settings/4.snap | 3 +- .../import_dump_v2_movie_with_settings/5.snap | 3 +- .../import_dump_v2_movie_with_settings/6.snap | 3 +- .../import_dump_v2_movie_with_settings/7.snap | 3 +- .../1.snap | 3 +- .../2.snap | 3 +- .../3.snap | 3 +- .../4.snap | 3 +- .../5.snap | 3 +- .../6.snap | 3 +- .../7.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/1.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/2.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/3.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/4.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/5.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/6.snap | 3 +- .../mod.rs/import_dump_v3_movie_raw/7.snap | 3 +- .../import_dump_v3_movie_with_settings/1.snap | 3 +- .../import_dump_v3_movie_with_settings/2.snap | 3 +- .../import_dump_v3_movie_with_settings/3.snap | 3 +- .../import_dump_v3_movie_with_settings/4.snap | 3 +- .../import_dump_v3_movie_with_settings/5.snap | 3 +- .../import_dump_v3_movie_with_settings/6.snap | 3 +- .../import_dump_v3_movie_with_settings/7.snap | 3 +- .../1.snap | 3 +- .../2.snap | 3 +- .../3.snap | 3 +- .../4.snap | 3 +- .../5.snap | 3 +- .../6.snap | 3 +- .../7.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/1.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/2.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/3.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/4.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/5.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/6.snap | 3 +- .../mod.rs/import_dump_v4_movie_raw/7.snap | 3 +- .../import_dump_v4_movie_with_settings/1.snap | 3 +- .../import_dump_v4_movie_with_settings/2.snap | 3 +- .../import_dump_v4_movie_with_settings/3.snap | 3 +- .../import_dump_v4_movie_with_settings/4.snap | 3 +- .../import_dump_v4_movie_with_settings/5.snap | 3 +- .../import_dump_v4_movie_with_settings/6.snap | 3 +- .../import_dump_v4_movie_with_settings/7.snap | 3 +- .../1.snap | 3 +- .../2.snap | 3 +- .../3.snap | 3 +- .../4.snap | 3 +- .../5.snap | 3 +- .../6.snap | 3 +- .../7.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/1.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/2.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/3.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/4.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/5.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/6.snap | 3 +- .../snapshots/mod.rs/import_dump_v5/7.snap | 3 +- .../distinct_at_search_time/succeed.snap | 3 +- crates/meilisearch/tests/snapshot/mod.rs | 1 + crates/meilisearch/tests/swap_indexes/mod.rs | 13 ++ crates/meilisearch/tests/tasks/mod.rs | 25 +++ crates/meilisearch/tests/tasks/webhook.rs | 8 +- .../tests/vector/binary_quantized.rs | 1 + crates/meilisearch/tests/vector/mod.rs | 12 ++ crates/meilisearch/tests/vector/openai.rs | 11 + crates/meilisearch/tests/vector/rest.rs | 20 ++ crates/meilisearch/tests/vector/settings.rs | 1 + .../document-added.snap | 3 +- .../document-deleted.snap | 3 +- .../settings-processed.snap | 3 +- 126 files changed, 755 insertions(+), 158 deletions(-) create mode 100644 crates/meilisearch-types/src/batches.rs create mode 100644 crates/meilisearch/src/routes/batches.rs diff --git a/crates/dump/src/lib.rs b/crates/dump/src/lib.rs index a17fcf941..8bed7f0d4 100644 --- a/crates/dump/src/lib.rs +++ b/crates/dump/src/lib.rs @@ -1,6 +1,7 @@ #![allow(clippy::type_complexity)] #![allow(clippy::wrong_self_convention)] +use meilisearch_types::batches::BatchId; use meilisearch_types::error::ResponseError; use meilisearch_types::keys::Key; use meilisearch_types::milli::update::IndexDocumentsMethod; @@ -57,6 +58,9 @@ pub enum Version { #[serde(rename_all = "camelCase")] pub struct TaskDump { pub uid: TaskId, + // The batch ID were introduced in v1.12, everything prior to this version will be `None`. + #[serde(default)] + pub batch_uid: Option, #[serde(default)] pub index_uid: Option, pub status: Status, @@ -143,6 +147,7 @@ impl From for TaskDump { fn from(task: Task) -> Self { TaskDump { uid: task.uid, + batch_uid: task.batch_uid, index_uid: task.index_uid().map(|uid| uid.to_string()), status: task.status, kind: task.kind.into(), @@ -297,6 +302,7 @@ pub(crate) mod test { ( TaskDump { uid: 0, + batch_uid: Some(0), index_uid: Some(S("doggo")), status: Status::Succeeded, kind: KindDump::DocumentImport { @@ -320,6 +326,7 @@ pub(crate) mod test { ( TaskDump { uid: 1, + batch_uid: None, index_uid: Some(S("doggo")), status: Status::Enqueued, kind: KindDump::DocumentImport { @@ -346,6 +353,7 @@ pub(crate) mod test { ( TaskDump { uid: 5, + batch_uid: None, index_uid: Some(S("catto")), status: Status::Enqueued, kind: KindDump::IndexDeletion, diff --git a/crates/dump/src/reader/compat/v5_to_v6.rs b/crates/dump/src/reader/compat/v5_to_v6.rs index 40a055465..9887c55ba 100644 --- a/crates/dump/src/reader/compat/v5_to_v6.rs +++ b/crates/dump/src/reader/compat/v5_to_v6.rs @@ -70,6 +70,7 @@ impl CompatV5ToV6 { let task = v6::Task { uid: task_view.uid, + batch_uid: None, index_uid: task_view.index_uid, status: match task_view.status { v5::Status::Enqueued => v6::Status::Enqueued, diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index 903ec1217..d64e2657a 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -24,6 +24,7 @@ use std::fs::{self, File}; use std::io::BufWriter; use dump::IndexMetadata; +use meilisearch_types::batches::BatchId; use meilisearch_types::error::Code; use meilisearch_types::heed::{RoTxn, RwTxn}; use meilisearch_types::milli::documents::{obkv_to_object, DocumentsBatchReader}; @@ -279,18 +280,22 @@ impl IndexScheduler { rtxn: &RoTxn, index_uid: String, batch: BatchKind, + batch_id: BatchId, must_create_index: bool, ) -> Result> { match batch { BatchKind::DocumentClear { ids } => Ok(Some(Batch::IndexOperation { op: IndexOperation::DocumentClear { - tasks: self.get_existing_tasks(rtxn, ids)?, + tasks: self.get_existing_tasks_with_batch_id(rtxn, batch_id, ids)?, index_uid, }, must_create_index, })), BatchKind::DocumentEdition { id } => { - let task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + let task = self + .get_task(rtxn, id)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id); match &task.kind { KindWithContent::DocumentEdition { index_uid, .. } => { Ok(Some(Batch::IndexOperation { @@ -305,7 +310,7 @@ impl IndexScheduler { } } BatchKind::DocumentOperation { method, operation_ids, .. } => { - let tasks = self.get_existing_tasks(rtxn, operation_ids)?; + let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, operation_ids)?; let primary_key = tasks .iter() .find_map(|task| match task.kind { @@ -352,7 +357,7 @@ impl IndexScheduler { })) } BatchKind::DocumentDeletion { deletion_ids, includes_by_filter: _ } => { - let tasks = self.get_existing_tasks(rtxn, deletion_ids)?; + let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, deletion_ids)?; Ok(Some(Batch::IndexOperation { op: IndexOperation::DocumentDeletion { index_uid, tasks }, @@ -360,7 +365,7 @@ impl IndexScheduler { })) } BatchKind::Settings { settings_ids, .. } => { - let tasks = self.get_existing_tasks(rtxn, settings_ids)?; + let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, settings_ids)?; let mut settings = Vec::new(); for task in &tasks { @@ -383,6 +388,7 @@ impl IndexScheduler { rtxn, index_uid, BatchKind::Settings { settings_ids, allow_index_creation }, + batch_id, must_create_index, )? .unwrap() @@ -398,6 +404,7 @@ impl IndexScheduler { rtxn, index_uid, BatchKind::DocumentClear { ids: other }, + batch_id, must_create_index, )? .unwrap() @@ -430,6 +437,7 @@ impl IndexScheduler { rtxn, index_uid.clone(), BatchKind::Settings { settings_ids, allow_index_creation }, + batch_id, must_create_index, )?; @@ -442,6 +450,7 @@ impl IndexScheduler { primary_key, operation_ids, }, + batch_id, must_create_index, )?; @@ -479,7 +488,10 @@ impl IndexScheduler { } } BatchKind::IndexCreation { id } => { - let task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + let task = self + .get_task(rtxn, id)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id); let (index_uid, primary_key) = match &task.kind { KindWithContent::IndexCreation { index_uid, primary_key } => { (index_uid.clone(), primary_key.clone()) @@ -489,7 +501,10 @@ impl IndexScheduler { Ok(Some(Batch::IndexCreation { index_uid, primary_key, task })) } BatchKind::IndexUpdate { id } => { - let task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + let task = self + .get_task(rtxn, id)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id); let primary_key = match &task.kind { KindWithContent::IndexUpdate { primary_key, .. } => primary_key.clone(), _ => unreachable!(), @@ -499,10 +514,13 @@ impl IndexScheduler { BatchKind::IndexDeletion { ids } => Ok(Some(Batch::IndexDeletion { index_uid, index_has_been_created: must_create_index, - tasks: self.get_existing_tasks(rtxn, ids)?, + tasks: self.get_existing_tasks_with_batch_id(rtxn, batch_id, ids)?, })), BatchKind::IndexSwap { id } => { - let task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + let task = self + .get_task(rtxn, id)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id); Ok(Some(Batch::IndexSwap { task })) } } @@ -515,10 +533,11 @@ impl IndexScheduler { /// 4. We get the *next* dump to process. /// 5. We get the *next* tasks to process for a specific index. #[tracing::instrument(level = "trace", skip(self, rtxn), target = "indexing::scheduler")] - pub(crate) fn create_next_batch(&self, rtxn: &RoTxn) -> Result> { + pub(crate) fn create_next_batch(&self, rtxn: &RoTxn) -> Result> { #[cfg(test)] self.maybe_fail(crate::tests::FailureLocation::InsideCreateBatch)?; + let batch_id = self.next_batch_id(rtxn)?; let enqueued = &self.get_status(rtxn, Status::Enqueued)?; let to_cancel = self.get_kind(rtxn, Kind::TaskCancelation)? & enqueued; @@ -526,39 +545,65 @@ impl IndexScheduler { if let Some(task_id) = to_cancel.max() { // We retrieve the tasks that were processing before this tasks cancelation started. // We must *not* reset the processing tasks before calling this method. - let ProcessingTasks { started_at, processing } = + // Displaying the `batch_id` would make a strange error message since this task cancelation is going to + // replace the canceled batch. It's better to avoid mentioning it in the error message. + let ProcessingTasks { started_at, batch_id: _, processing } = &*self.processing_tasks.read().unwrap(); - return Ok(Some(Batch::TaskCancelation { - task: self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?, - previous_started_at: *started_at, - previous_processing_tasks: processing.clone(), - })); + return Ok(Some(( + Batch::TaskCancelation { + task: self + .get_task(rtxn, task_id)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id), + previous_started_at: *started_at, + previous_processing_tasks: processing.clone(), + }, + batch_id, + ))); } // 2. we get the next task to delete let to_delete = self.get_kind(rtxn, Kind::TaskDeletion)? & enqueued; if !to_delete.is_empty() { - let tasks = self.get_existing_tasks(rtxn, to_delete)?; - return Ok(Some(Batch::TaskDeletions(tasks))); + let tasks = self + .get_existing_tasks(rtxn, to_delete)? + .into_iter() + .map(|task| task.with_batch_id(batch_id)) + .collect(); + return Ok(Some((Batch::TaskDeletions(tasks), batch_id))); } // 3. we batch the snapshot. let to_snapshot = self.get_kind(rtxn, Kind::SnapshotCreation)? & enqueued; if !to_snapshot.is_empty() { - return Ok(Some(Batch::SnapshotCreation(self.get_existing_tasks(rtxn, to_snapshot)?))); + return Ok(Some(( + Batch::SnapshotCreation( + self.get_existing_tasks(rtxn, to_snapshot)? + .into_iter() + .map(|task| task.with_batch_id(batch_id)) + .collect(), + ), + batch_id, + ))); } // 4. we batch the dumps. let to_dump = self.get_kind(rtxn, Kind::DumpCreation)? & enqueued; if let Some(to_dump) = to_dump.min() { - return Ok(Some(Batch::Dump( - self.get_task(rtxn, to_dump)?.ok_or(Error::CorruptedTaskQueue)?, + return Ok(Some(( + Batch::Dump( + self.get_task(rtxn, to_dump)? + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id), + ), + batch_id, ))); } // 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 task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; + let task = + self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?.with_batch_id(batch_id); // 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 @@ -568,7 +613,7 @@ impl IndexScheduler { index_name } else { assert!(matches!(&task.kind, KindWithContent::IndexSwap { swaps } if swaps.is_empty())); - return Ok(Some(Batch::IndexSwap { task })); + return Ok(Some((Batch::IndexSwap { task }, batch_id))); }; let index_already_exists = self.index_mapper.exists(rtxn, index_name)?; @@ -599,12 +644,15 @@ impl IndexScheduler { if let Some((batchkind, create_index)) = autobatcher::autobatch(enqueued, index_already_exists, primary_key.as_deref()) { - return self.create_next_batch_index( - rtxn, - index_name.to_string(), - batchkind, - create_index, - ); + return Ok(self + .create_next_batch_index( + rtxn, + index_name.to_string(), + batchkind, + batch_id, + create_index, + )? + .map(|batch| (batch, batch_id))); } // If we found no tasks then we were notified for something that got autobatched diff --git a/crates/index-scheduler/src/error.rs b/crates/index-scheduler/src/error.rs index 3bd378fd6..434764677 100644 --- a/crates/index-scheduler/src/error.rs +++ b/crates/index-scheduler/src/error.rs @@ -79,7 +79,9 @@ pub enum Error { )] InvalidTaskDate { field: DateField, date: String }, #[error("Task uid `{task_uid}` is invalid. It should only contain numeric characters.")] - InvalidTaskUids { task_uid: String }, + InvalidTaskUid { task_uid: String }, + #[error("Batch uid `{batch_uid}` is invalid. It should only contain numeric characters.")] + InvalidBatchUid { batch_uid: String }, #[error( "Task status `{status}` is invalid. Available task statuses are {}.", enum_iterator::all::() @@ -172,7 +174,8 @@ impl Error { | Error::SwapIndexesNotFound(_) | Error::CorruptedDump | Error::InvalidTaskDate { .. } - | Error::InvalidTaskUids { .. } + | Error::InvalidTaskUid { .. } + | Error::InvalidBatchUid { .. } | Error::InvalidTaskStatuses { .. } | Error::InvalidTaskTypes { .. } | Error::InvalidTaskCanceledBy { .. } @@ -216,7 +219,8 @@ impl ErrorCode for Error { Error::SwapIndexNotFound(_) => Code::IndexNotFound, Error::SwapIndexesNotFound(_) => Code::IndexNotFound, Error::InvalidTaskDate { field, .. } => (*field).into(), - Error::InvalidTaskUids { .. } => Code::InvalidTaskUids, + Error::InvalidTaskUid { .. } => Code::InvalidTaskUids, + Error::InvalidBatchUid { .. } => Code::InvalidBatchUids, Error::InvalidTaskStatuses { .. } => Code::InvalidTaskStatuses, Error::InvalidTaskTypes { .. } => Code::InvalidTaskTypes, Error::InvalidTaskCanceledBy { .. } => Code::InvalidTaskCanceledBy, diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index f295e35b6..f2b9df555 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -24,6 +24,8 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { file_store, env, all_tasks, + all_batches, + // task reverse index status, kind, index_tasks, @@ -31,6 +33,16 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { enqueued_at, started_at, finished_at, + + // batch reverse index + batch_status, + batch_kind, + batch_index_tasks, + batch_canceled_by, + batch_enqueued_at, + batch_started_at, + batch_finished_at, + index_mapper, features: _, max_number_of_tasks: _, @@ -145,6 +157,7 @@ pub fn snapshot_task(task: &Task) -> String { let mut snap = String::new(); let Task { uid, + batch_uid, enqueued_at: _, started_at: _, finished_at: _, @@ -156,6 +169,9 @@ pub fn snapshot_task(task: &Task) -> String { } = task; snap.push('{'); snap.push_str(&format!("uid: {uid}, ")); + if let Some(batch_uid) = batch_uid { + snap.push_str(&format!("batch_uid: {batch_uid}, ")); + } snap.push_str(&format!("status: {status}, ")); if let Some(canceled_by) = canceled_by { snap.push_str(&format!("canceled_by: {canceled_by}, ")); diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 336a43b1b..855dd8026 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -48,6 +48,7 @@ pub use features::RoFeatures; use file_store::FileStore; use flate2::bufread::GzEncoder; use flate2::Compression; +use meilisearch_types::batches::{Batch, BatchId}; use meilisearch_types::error::ResponseError; use meilisearch_types::features::{InstanceTogglableFeatures, RuntimeTogglableFeatures}; use meilisearch_types::heed::byteorder::BE; @@ -162,6 +163,8 @@ impl Query { struct ProcessingTasks { /// The date and time at which the indexation started. started_at: OffsetDateTime, + /// The id of the batch processing + batch_id: Option, /// The list of tasks ids that are currently running. processing: RoaringBitmap, } @@ -169,17 +172,28 @@ struct ProcessingTasks { impl ProcessingTasks { /// Creates an empty `ProcessingAt` struct. fn new() -> ProcessingTasks { - ProcessingTasks { started_at: OffsetDateTime::now_utc(), processing: RoaringBitmap::new() } + ProcessingTasks { + started_at: OffsetDateTime::now_utc(), + batch_id: None, + processing: RoaringBitmap::new(), + } } /// Stores the currently processing tasks, and the date time at which it started. - fn start_processing_at(&mut self, started_at: OffsetDateTime, processing: RoaringBitmap) { + fn start_processing( + &mut self, + started_at: OffsetDateTime, + batch_id: BatchId, + processing: RoaringBitmap, + ) { self.started_at = started_at; + self.batch_id = Some(batch_id); self.processing = processing; } /// Set the processing tasks to an empty list fn stop_processing(&mut self) -> RoaringBitmap { + self.batch_id = None; std::mem::take(&mut self.processing) } @@ -209,6 +223,7 @@ impl MustStopProcessing { /// Database const names for the `IndexScheduler`. mod db_name { pub const ALL_TASKS: &str = "all-tasks"; + pub const ALL_BATCHES: &str = "all-batches"; pub const STATUS: &str = "status"; pub const KIND: &str = "kind"; pub const INDEX_TASKS: &str = "index-tasks"; @@ -216,6 +231,14 @@ mod db_name { pub const ENQUEUED_AT: &str = "enqueued-at"; pub const STARTED_AT: &str = "started-at"; pub const FINISHED_AT: &str = "finished-at"; + + pub const BATCH_STATUS: &str = "batch-status"; + pub const BATCH_KIND: &str = "batch-kind"; + pub const BATCH_INDEX_TASKS: &str = "batch-index-tasks"; + pub const BATCH_CANCELED_BY: &str = "batch-canceled_by"; + pub const BATCH_ENQUEUED_AT: &str = "batch-enqueued-at"; + pub const BATCH_STARTED_AT: &str = "batch-started-at"; + pub const BATCH_FINISHED_AT: &str = "batch-finished-at"; } #[cfg(test)] @@ -300,6 +323,28 @@ pub struct IndexScheduler { // The main database, it contains all the tasks accessible by their Id. pub(crate) all_tasks: Database>, + // Contains all the batches accessible by their Id. + pub(crate) all_batches: Database>, + + /// All the batches containing a task matching the selected status. + pub(crate) batch_status: Database, RoaringBitmapCodec>, + /// All the batches ids grouped by the kind of their task. + pub(crate) batch_kind: Database, RoaringBitmapCodec>, + /// Store the batches associated to an index. + pub(crate) batch_index_tasks: Database, + + /// Store the batches containing a task canceled by a task uid + pub(crate) batch_canceled_by: Database, + + /// Store the batches containing tasks which were enqueued at a specific date + pub(crate) batch_enqueued_at: Database, + + /// Store the batches containing finished tasks started at a specific date + pub(crate) batch_started_at: Database, + + /// Store the batches containing tasks finished at a specific date + pub(crate) batch_finished_at: Database, + /// All the tasks ids grouped by their status. // TODO we should not be able to serialize a `Status::Processing` in this database. pub(crate) status: Database, RoaringBitmapCodec>, @@ -388,6 +433,9 @@ impl IndexScheduler { processing_tasks: self.processing_tasks.clone(), file_store: self.file_store.clone(), all_tasks: self.all_tasks, + all_batches: self.all_batches, + + // Tasks reverse index status: self.status, kind: self.kind, index_tasks: self.index_tasks, @@ -395,6 +443,16 @@ impl IndexScheduler { enqueued_at: self.enqueued_at, started_at: self.started_at, finished_at: self.finished_at, + + // Batches reverse index + batch_status: self.batch_status, + batch_kind: self.batch_kind, + batch_index_tasks: self.batch_index_tasks, + batch_canceled_by: self.batch_canceled_by, + batch_enqueued_at: self.batch_enqueued_at, + batch_started_at: self.batch_started_at, + batch_finished_at: self.batch_finished_at, + index_mapper: self.index_mapper.clone(), wake_up: self.wake_up.clone(), autobatching_enabled: self.autobatching_enabled, @@ -454,7 +512,7 @@ impl IndexScheduler { let env = unsafe { heed::EnvOpenOptions::new() - .max_dbs(11) + .max_dbs(19) .map_size(budget.task_db_size) .open(options.tasks_path) }?; @@ -465,6 +523,7 @@ impl IndexScheduler { let mut wtxn = env.write_txn()?; let all_tasks = env.create_database(&mut wtxn, Some(db_name::ALL_TASKS))?; + let all_batches = env.create_database(&mut wtxn, Some(db_name::ALL_BATCHES))?; let status = env.create_database(&mut wtxn, Some(db_name::STATUS))?; let kind = env.create_database(&mut wtxn, Some(db_name::KIND))?; let index_tasks = env.create_database(&mut wtxn, Some(db_name::INDEX_TASKS))?; @@ -472,6 +531,14 @@ impl IndexScheduler { let enqueued_at = env.create_database(&mut wtxn, Some(db_name::ENQUEUED_AT))?; let started_at = env.create_database(&mut wtxn, Some(db_name::STARTED_AT))?; let finished_at = env.create_database(&mut wtxn, Some(db_name::FINISHED_AT))?; + + let batch_status = env.create_database(&mut wtxn, Some(db_name::STATUS))?; + let batch_kind = env.create_database(&mut wtxn, Some(db_name::KIND))?; + let batch_index_tasks = env.create_database(&mut wtxn, Some(db_name::INDEX_TASKS))?; + let batch_canceled_by = env.create_database(&mut wtxn, Some(db_name::CANCELED_BY))?; + let batch_enqueued_at = env.create_database(&mut wtxn, Some(db_name::ENQUEUED_AT))?; + let batch_started_at = env.create_database(&mut wtxn, Some(db_name::STARTED_AT))?; + let batch_finished_at = env.create_database(&mut wtxn, Some(db_name::FINISHED_AT))?; wtxn.commit()?; // allow unreachable_code to get rids of the warning in the case of a test build. @@ -480,6 +547,8 @@ impl IndexScheduler { processing_tasks: Arc::new(RwLock::new(ProcessingTasks::new())), file_store, all_tasks, + all_batches, + // Task reverse indexes status, kind, index_tasks, @@ -487,6 +556,16 @@ impl IndexScheduler { enqueued_at, started_at, finished_at, + + // Batch reverse indexes + batch_status, + batch_kind, + batch_index_tasks, + batch_canceled_by, + batch_enqueued_at, + batch_started_at, + batch_finished_at, + index_mapper: IndexMapper::new( &env, options.indexes_path, @@ -946,6 +1025,52 @@ impl IndexScheduler { Ok((tasks, total_tasks.len())) } + /// Return the batch ids matching the query along with the total number of batches + /// by ignoring the from and limit parameters from the user's point of view. + /// + /// There are two differences between an internal query and a query executed by + /// the user. + /// + /// 1. IndexSwap tasks are not publicly associated with any index, but they are associated + /// with many indexes internally. + /// 2. The user may not have the rights to access the tasks (internally) associated with all indexes. + pub fn get_task_ids_from_authorized_indexes( + &self, + rtxn: &RoTxn, + query: &Query, + filters: &meilisearch_auth::AuthFilter, + ) -> Result<(RoaringBitmap, u64)> { + // compute all batches matching the filter by ignoring the limits, to find the number of batches matching + // the filter. + // As this causes us to compute the filter twice it is slightly inefficient, but doing it this way spares + // us from modifying the underlying implementation, and the performance remains sufficient. + // Should this change, we would modify `get_batch_ids` to directly return the number of matching batches. + let total_batches = self.get_batch_ids(rtxn, &query.clone().without_limits())?; + let mut batches = self.get_batch_ids(rtxn, query)?; + + // If the query contains a list of index uid or there is a finite list of authorized indexes, + // then we must exclude all the kinds that aren't associated to one and only one index. + if query.index_uids.is_some() || !filters.all_indexes_authorized() { + for kind in enum_iterator::all::().filter(|kind| !kind.related_to_one_index()) { + batches -= self.get_kind(rtxn, kind)?; + } + } + + // Any task that is internally associated with a non-authorized index + // must be discarded. + if !filters.all_indexes_authorized() { + let all_indexes_iter = self.index_tasks.iter(rtxn)?; + for result in all_indexes_iter { + let (index, index_tasks) = result?; + if !filters.is_index_authorized(index) { + tasks -= index_tasks; + } + } + } + + Ok((tasks, total_tasks.len())) + } + /// Return the tasks matching the query from the user's point of view along /// with the total number of tasks matching the query, ignoring from and limit. /// @@ -971,7 +1096,7 @@ impl IndexScheduler { let tasks = self.get_existing_tasks(&rtxn, tasks.take(query.limit.unwrap_or(u32::MAX) as usize))?; - let ProcessingTasks { started_at, processing, .. } = + let ProcessingTasks { started_at, batch_id, processing } = self.processing_tasks.read().map_err(|_| Error::CorruptedTaskQueue)?.clone(); let ret = tasks.into_iter(); @@ -981,7 +1106,60 @@ impl IndexScheduler { Ok(( ret.map(|task| { if processing.contains(task.uid) { - Task { status: Status::Processing, started_at: Some(started_at), ..task } + Task { + status: Status::Processing, + batch_uid: batch_id, + started_at: Some(started_at), + ..task + } + } else { + task + } + }) + .collect(), + total, + )) + } + } + + /// Return the batches matching the query from the user's point of view along + /// with the total number of batches matching the query, ignoring from and limit. + /// + /// There are two differences between an internal query and a query executed by + /// the user. + /// + /// 1. IndexSwap tasks are not publicly associated with any index, but they are associated + /// with many indexes internally. + /// 2. The user may not have the rights to access the tasks (internally) associated with all indexes. + pub fn get_batches_from_authorized_indexes( + &self, + query: Query, + filters: &meilisearch_auth::AuthFilter, + ) -> Result<(Vec, u64)> { + let rtxn = self.env.read_txn()?; + + let (tasks, total) = self.get_batch_ids_from_authorized_indexes(&rtxn, &query, filters)?; + let tasks = self.get_existing_batches( + &rtxn, + tasks.into_iter().rev().take(query.limit.unwrap_or(u32::MAX) as usize), + )?; + + let ProcessingTasks { started_at, batch_id, processing } = + self.processing_tasks.read().map_err(|_| Error::CorruptedTaskQueue)?.clone(); + + let ret = tasks.into_iter(); + if processing.is_empty() { + Ok((ret.collect(), total)) + } else { + Ok(( + ret.map(|task| { + if processing.contains(task.uid) { + Task { + status: Status::Processing, + batch_uid: batch_id, + started_at: Some(started_at), + ..task + } } else { task } @@ -1020,6 +1198,8 @@ impl IndexScheduler { let mut task = Task { uid: task_id.unwrap_or(next_task_id), + // The batch is defined once we starts processing the task + batch_uid: None, enqueued_at: OffsetDateTime::now_utc(), started_at: None, finished_at: None, @@ -1155,7 +1335,7 @@ impl IndexScheduler { } let rtxn = self.env.read_txn().map_err(Error::HeedTransaction)?; - let batch = + let (batch, batch_id) = match self.create_next_batch(&rtxn).map_err(|e| Error::CreateBatch(Box::new(e)))? { Some(batch) => batch, None => return Ok(TickOutcome::WaitForSignal), @@ -1170,7 +1350,7 @@ impl IndexScheduler { // We reset the must_stop flag to be sure that we don't stop processing tasks self.must_stop_processing.reset(); - self.processing_tasks.write().unwrap().start_processing_at(started_at, ids.clone()); + self.processing_tasks.write().unwrap().start_processing(started_at, batch_id, ids.clone()); #[cfg(test)] self.breakpoint(Breakpoint::BatchCreated); @@ -1268,7 +1448,8 @@ impl IndexScheduler { let mut task = self .get_task(&wtxn, id) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))? - .ok_or(Error::CorruptedTaskQueue)?; + .ok_or(Error::CorruptedTaskQueue)? + .with_batch_id(batch_id); task.started_at = Some(started_at); task.finished_at = Some(finished_at); task.status = Status::Failed; @@ -1286,6 +1467,12 @@ impl IndexScheduler { } } + self.all_batches.put( + &mut wtxn, + &batch_id, + &Batch { uid: batch_id, started_at, finished_at: Some(finished_at) }, + )?; + let processed = self.processing_tasks.write().unwrap().stop_processing(); #[cfg(test)] @@ -1600,6 +1787,7 @@ impl<'a> Dump<'a> { let task = Task { uid: task.uid, + batch_uid: task.batch_uid, enqueued_at: task.enqueued_at, started_at: task.started_at, finished_at: task.finished_at, diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 788a70fb8..534d3b5d4 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -3,6 +3,7 @@ use std::collections::{BTreeSet, HashSet}; use std::ops::Bound; +use meilisearch_types::batches::BatchId; use meilisearch_types::heed::types::DecodeIgnore; use meilisearch_types::heed::{Database, RoTxn, RwTxn}; use meilisearch_types::milli::CboRoaringBitmapCodec; @@ -25,10 +26,37 @@ impl IndexScheduler { Ok(self.last_task_id(rtxn)?.unwrap_or_default()) } + pub(crate) fn next_batch_id(&self, rtxn: &RoTxn) -> Result { + Ok(self + .all_batches + .remap_data_type::() + .last(rtxn)? + .map(|(k, _)| k + 1) + .unwrap_or_default()) + } + pub(crate) fn get_task(&self, rtxn: &RoTxn, task_id: TaskId) -> Result> { Ok(self.all_tasks.get(rtxn, &task_id)?) } + /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a + /// `CorruptedTaskQueue` error will be throwed. + pub(crate) fn get_existing_tasks_with_batch_id( + &self, + rtxn: &RoTxn, + batch_id: BatchId, + tasks: impl IntoIterator, + ) -> Result> { + tasks + .into_iter() + .map(|task_id| { + self.get_task(rtxn, task_id) + .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)) + .map(|task| task.with_batch_id(batch_id)) + }) + .collect::>() + } + /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a /// `CorruptedTaskQueue` error will be throwed. pub(crate) fn get_existing_tasks( @@ -342,6 +370,8 @@ impl IndexScheduler { let Task { uid, + /// We should iterate over the list of batch to ensure this task is effectively in the right batch + batch_uid, enqueued_at, started_at, finished_at, diff --git a/crates/meilisearch-types/src/batches.rs b/crates/meilisearch-types/src/batches.rs new file mode 100644 index 000000000..8a439c59f --- /dev/null +++ b/crates/meilisearch-types/src/batches.rs @@ -0,0 +1,18 @@ +use serde::{Deserialize, Serialize}; +use time::OffsetDateTime; + +pub type BatchId = u32; + +#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[serde(rename_all = "camelCase")] +pub struct Batch { + pub uid: BatchId, + + #[serde(with = "time::serde::rfc3339")] + pub started_at: OffsetDateTime, + #[serde(with = "time::serde::rfc3339::option")] + pub finished_at: Option, + // pub details: Option
, + + // pub status: Status, +} diff --git a/crates/meilisearch-types/src/error.rs b/crates/meilisearch-types/src/error.rs index ef530fc6b..c2c40be5f 100644 --- a/crates/meilisearch-types/src/error.rs +++ b/crates/meilisearch-types/src/error.rs @@ -322,6 +322,7 @@ InvalidTaskReverse , InvalidRequest , BAD_REQUEST ; InvalidTaskStatuses , InvalidRequest , BAD_REQUEST ; InvalidTaskTypes , InvalidRequest , BAD_REQUEST ; InvalidTaskUids , InvalidRequest , BAD_REQUEST ; +InvalidBatchUids , InvalidRequest , BAD_REQUEST ; IoError , System , UNPROCESSABLE_ENTITY; FeatureNotEnabled , InvalidRequest , BAD_REQUEST ; MalformedPayload , InvalidRequest , BAD_REQUEST ; diff --git a/crates/meilisearch-types/src/lib.rs b/crates/meilisearch-types/src/lib.rs index d6049e667..e10b2950b 100644 --- a/crates/meilisearch-types/src/lib.rs +++ b/crates/meilisearch-types/src/lib.rs @@ -1,3 +1,4 @@ +pub mod batches; pub mod compression; pub mod deserr; pub mod document_formats; diff --git a/crates/meilisearch-types/src/task_view.rs b/crates/meilisearch-types/src/task_view.rs index 3075fa899..0cc127c0d 100644 --- a/crates/meilisearch-types/src/task_view.rs +++ b/crates/meilisearch-types/src/task_view.rs @@ -2,6 +2,7 @@ use milli::Object; use serde::Serialize; use time::{Duration, OffsetDateTime}; +use crate::batches::BatchId; use crate::error::ResponseError; use crate::settings::{Settings, Unchecked}; use crate::tasks::{serialize_duration, Details, IndexSwap, Kind, Status, Task, TaskId}; @@ -10,6 +11,7 @@ use crate::tasks::{serialize_duration, Details, IndexSwap, Kind, Status, Task, T #[serde(rename_all = "camelCase")] pub struct TaskView { pub uid: TaskId, + pub batch_uid: Option, #[serde(default)] pub index_uid: Option, pub status: Status, @@ -33,6 +35,7 @@ impl TaskView { pub fn from_task(task: &Task) -> TaskView { TaskView { uid: task.uid, + batch_uid: task.batch_uid, index_uid: task.index_uid().map(ToOwned::to_owned), status: task.status, kind: task.kind.as_kind(), diff --git a/crates/meilisearch-types/src/tasks.rs b/crates/meilisearch-types/src/tasks.rs index 1dd6d3fbf..3485962d1 100644 --- a/crates/meilisearch-types/src/tasks.rs +++ b/crates/meilisearch-types/src/tasks.rs @@ -11,6 +11,7 @@ use serde::{Deserialize, Serialize, Serializer}; use time::{Duration, OffsetDateTime}; use uuid::Uuid; +use crate::batches::BatchId; use crate::error::ResponseError; use crate::keys::Key; use crate::settings::{Settings, Unchecked}; @@ -22,6 +23,7 @@ pub type TaskId = u32; #[serde(rename_all = "camelCase")] pub struct Task { pub uid: TaskId, + pub batch_uid: Option, #[serde(with = "time::serde::rfc3339")] pub enqueued_at: OffsetDateTime, @@ -60,6 +62,11 @@ impl Task { } } + pub fn with_batch_id(mut self, batch_id: TaskId) -> Self { + self.batch_uid = Some(batch_id); + self + } + /// Return the list of indexes updated by this tasks. pub fn indexes(&self) -> Vec<&str> { self.kind.indexes() diff --git a/crates/meilisearch/src/routes/batches.rs b/crates/meilisearch/src/routes/batches.rs new file mode 100644 index 000000000..f8e626a17 --- /dev/null +++ b/crates/meilisearch/src/routes/batches.rs @@ -0,0 +1,48 @@ +use actix_web::{ + web::{self, Data}, + HttpResponse, +}; +use index_scheduler::{IndexScheduler, Query}; +use meilisearch_types::{ + batches::BatchId, error::ResponseError, keys::actions, task_view::TaskView, +}; + +use crate::extractors::{authentication::GuardedData, sequential_extractor::SeqHandler}; + +use super::ActionPolicy; + +pub fn configure(cfg: &mut web::ServiceConfig) { + cfg + // .service( + // web::resource("") + // .route(web::get().to(SeqHandler(get_tasks))) + // ) + .service(web::resource("/{batch_id}").route(web::get().to(SeqHandler(get_batch)))); +} + +async fn get_task( + index_scheduler: GuardedData, Data>, + batch_uid: web::Path, +) -> Result { + let batch_uid_string = batch_uid.into_inner(); + + let batch_uid: BatchId = match batch_uid_string.parse() { + Ok(id) => id, + Err(_e) => { + return Err( + index_scheduler::Error::InvalidBatchUid { batch_uid: batch_uid_string }.into() + ) + } + }; + + let query = index_scheduler::Query { uids: Some(vec![batch_uid]), ..Query::default() }; + let filters = index_scheduler.filters(); + let (tasks, _) = index_scheduler.get_tasks_from_authorized_indexes(query, filters)?; + + if let Some(task) = tasks.first() { + let task_view = TaskView::from_task(task); + Ok(HttpResponse::Ok().json(task_view)) + } else { + Err(index_scheduler::Error::TaskNotFound(batch_uid).into()) + } +} diff --git a/crates/meilisearch/src/routes/mod.rs b/crates/meilisearch/src/routes/mod.rs index b7260ea08..f5c512ab9 100644 --- a/crates/meilisearch/src/routes/mod.rs +++ b/crates/meilisearch/src/routes/mod.rs @@ -19,6 +19,7 @@ use crate::Opt; const PAGINATION_DEFAULT_LIMIT: usize = 20; mod api_key; +pub mod batches; mod dump; pub mod features; pub mod indexes; diff --git a/crates/meilisearch/src/routes/tasks.rs b/crates/meilisearch/src/routes/tasks.rs index e2a787d12..556b71bc5 100644 --- a/crates/meilisearch/src/routes/tasks.rs +++ b/crates/meilisearch/src/routes/tasks.rs @@ -17,15 +17,13 @@ use time::macros::format_description; use time::{Date, Duration, OffsetDateTime, Time}; use tokio::task; -use super::{get_task_id, is_dry_run, SummarizedTaskView}; +use super::{get_task_id, is_dry_run, SummarizedTaskView, PAGINATION_DEFAULT_LIMIT}; use crate::analytics::{Aggregate, AggregateMethod, Analytics}; use crate::extractors::authentication::policies::*; use crate::extractors::authentication::GuardedData; use crate::extractors::sequential_extractor::SeqHandler; use crate::{aggregate_methods, Opt}; -const DEFAULT_LIMIT: u32 = 20; - pub fn configure(cfg: &mut web::ServiceConfig) { cfg.service( web::resource("") @@ -35,10 +33,11 @@ pub fn configure(cfg: &mut web::ServiceConfig) { .service(web::resource("/cancel").route(web::post().to(SeqHandler(cancel_tasks)))) .service(web::resource("/{task_id}").route(web::get().to(SeqHandler(get_task)))); } + #[derive(Debug, Deserr)] #[deserr(error = DeserrQueryParamError, rename_all = camelCase, deny_unknown_fields)] pub struct TasksFilterQuery { - #[deserr(default = Param(DEFAULT_LIMIT), error = DeserrQueryParamError)] + #[deserr(default = Param(PAGINATION_DEFAULT_LIMIT as u32), error = DeserrQueryParamError)] pub limit: Param, #[deserr(default, error = DeserrQueryParamError)] pub from: Option>, @@ -363,7 +362,7 @@ async fn get_task( let task_uid: TaskId = match task_uid_string.parse() { Ok(id) => id, Err(_e) => { - return Err(index_scheduler::Error::InvalidTaskUids { task_uid: task_uid_string }.into()) + return Err(index_scheduler::Error::InvalidTaskUid { task_uid: task_uid_string }.into()) } }; diff --git a/crates/meilisearch/tests/common/mod.rs b/crates/meilisearch/tests/common/mod.rs index a0137931d..3aae2fe80 100644 --- a/crates/meilisearch/tests/common/mod.rs +++ b/crates/meilisearch/tests/common/mod.rs @@ -99,6 +99,7 @@ impl Display for Value { "{}", json_string!(self, { ".uid" => "[uid]", + ".batchUid" => "[batch_uid]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", diff --git a/crates/meilisearch/tests/documents/add_documents.rs b/crates/meilisearch/tests/documents/add_documents.rs index c37b3a5e3..cec6f0791 100644 --- a/crates/meilisearch/tests/documents/add_documents.rs +++ b/crates/meilisearch/tests/documents/add_documents.rs @@ -293,6 +293,7 @@ async fn add_csv_document() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 0, + "batchUid": 0, "indexUid": "pets", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -357,6 +358,7 @@ async fn add_csv_document_with_types() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 0, + "batchUid": 0, "indexUid": "pets", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -432,6 +434,7 @@ async fn add_csv_document_with_custom_delimiter() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 0, + "batchUid": 0, "indexUid": "pets", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -985,6 +988,7 @@ async fn add_documents_no_index_creation() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1063,6 +1067,7 @@ async fn document_addition_with_primary_key() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1111,6 +1116,7 @@ async fn document_addition_with_huge_int_primary_key() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1183,6 +1189,7 @@ async fn replace_document() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1271,6 +1278,7 @@ async fn error_add_documents_bad_document_id() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1312,6 +1320,7 @@ async fn error_add_documents_missing_document_id() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1403,6 +1412,7 @@ async fn error_document_field_limit_reached_over_multiple_documents() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1437,6 +1447,7 @@ async fn error_document_field_limit_reached_over_multiple_documents() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1486,6 +1497,7 @@ async fn error_document_field_limit_reached_in_one_nested_document() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1529,6 +1541,7 @@ async fn error_document_field_limit_reached_over_multiple_documents_with_nested_ @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1564,6 +1577,7 @@ async fn error_document_field_limit_reached_over_multiple_documents_with_nested_ @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1611,6 +1625,7 @@ async fn add_documents_with_geo_field() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1651,6 +1666,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 2, + "batchUid": 2, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1688,6 +1704,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 3, + "batchUid": 3, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1725,6 +1742,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 4, + "batchUid": 4, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1762,6 +1780,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 5, + "batchUid": 5, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1799,6 +1818,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 6, + "batchUid": 6, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1836,6 +1856,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 7, + "batchUid": 7, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1873,6 +1894,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 8, + "batchUid": 8, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1910,6 +1932,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 9, + "batchUid": 9, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1947,6 +1970,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 10, + "batchUid": 10, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1984,6 +2008,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 11, + "batchUid": 11, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2021,6 +2046,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 12, + "batchUid": 12, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2058,6 +2084,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 13, + "batchUid": 13, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2096,6 +2123,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 14, + "batchUid": 14, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2132,6 +2160,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 15, + "batchUid": 15, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2168,6 +2197,7 @@ async fn add_documents_invalid_geo_field() { @r###" { "uid": 16, + "batchUid": 16, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2210,6 +2240,7 @@ async fn add_invalid_geo_and_then_settings() { snapshot!(ret, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -2232,6 +2263,7 @@ async fn add_invalid_geo_and_then_settings() { snapshot!(ret, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "failed", "type": "settingsUpdate", @@ -2303,6 +2335,7 @@ async fn error_primary_key_inference() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2343,6 +2376,7 @@ async fn error_primary_key_inference() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "failed", "type": "documentAdditionOrUpdate", @@ -2381,6 +2415,7 @@ async fn error_primary_key_inference() { @r###" { "uid": 2, + "batchUid": 2, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/documents/delete_documents.rs b/crates/meilisearch/tests/documents/delete_documents.rs index 5a15e95ff..c50823183 100644 --- a/crates/meilisearch/tests/documents/delete_documents.rs +++ b/crates/meilisearch/tests/documents/delete_documents.rs @@ -184,6 +184,7 @@ async fn delete_document_by_filter() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 2, + "batchUid": 2, "indexUid": "doggo", "status": "succeeded", "type": "documentDeletion", @@ -249,6 +250,7 @@ async fn delete_document_by_filter() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 3, + "batchUid": 3, "indexUid": "doggo", "status": "succeeded", "type": "documentDeletion", @@ -333,6 +335,7 @@ async fn delete_document_by_complex_filter() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 2, + "batchUid": 2, "indexUid": "doggo", "status": "succeeded", "type": "documentDeletion", @@ -391,6 +394,7 @@ async fn delete_document_by_complex_filter() { snapshot!(json_string!(response, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 3, + "batchUid": 3, "indexUid": "doggo", "status": "succeeded", "type": "documentDeletion", diff --git a/crates/meilisearch/tests/documents/errors.rs b/crates/meilisearch/tests/documents/errors.rs index 4c644ae98..c90b9ed49 100644 --- a/crates/meilisearch/tests/documents/errors.rs +++ b/crates/meilisearch/tests/documents/errors.rs @@ -563,6 +563,7 @@ async fn delete_document_by_filter() { snapshot!(response, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "DOES_NOT_EXISTS", "status": "failed", "type": "documentDeletion", @@ -592,6 +593,7 @@ async fn delete_document_by_filter() { snapshot!(response, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "EMPTY_INDEX", "status": "failed", "type": "documentDeletion", @@ -623,6 +625,7 @@ async fn delete_document_by_filter() { snapshot!(response, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "SHARED_DOCUMENTS", "status": "failed", "type": "documentDeletion", diff --git a/crates/meilisearch/tests/dumps/mod.rs b/crates/meilisearch/tests/dumps/mod.rs index 1c1a8e649..c7d157b00 100644 --- a/crates/meilisearch/tests/dumps/mod.rs +++ b/crates/meilisearch/tests/dumps/mod.rs @@ -88,7 +88,7 @@ async fn import_dump_v1_movie_raw() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{"uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31968 }, "error": null, "duration": "PT9.317060500S", "enqueuedAt": "2021-09-08T09:08:45.153219Z", "startedAt": "2021-09-08T09:08:45.3961665Z", "finishedAt": "2021-09-08T09:08:54.713227Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) + json!({ "results": [{"uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31968 }, "error": null, "duration": "PT9.317060500S", "enqueuedAt": "2021-09-08T09:08:45.153219Z", "startedAt": "2021-09-08T09:08:45.3961665Z", "finishedAt": "2021-09-08T09:08:54.713227Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -251,7 +251,7 @@ async fn import_dump_v1_movie_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{ "uid": 1, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["genres", "id", "overview", "poster", "release_date", "title"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "sortableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT7.288826907S", "enqueuedAt": "2021-09-08T09:34:40.882977Z", "startedAt": "2021-09-08T09:34:40.883073093Z", "finishedAt": "2021-09-08T09:34:48.1719Z"}, { "uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31968 }, "error": null, "duration": "PT9.090735774S", "enqueuedAt": "2021-09-08T09:34:16.036101Z", "startedAt": "2021-09-08T09:34:16.261191226Z", "finishedAt": "2021-09-08T09:34:25.351927Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) + json!({ "results": [{ "uid": 1, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["genres", "id", "overview", "poster", "release_date", "title"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "sortableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT7.288826907S", "enqueuedAt": "2021-09-08T09:34:40.882977Z", "startedAt": "2021-09-08T09:34:40.883073093Z", "finishedAt": "2021-09-08T09:34:48.1719Z"}, { "uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31968 }, "error": null, "duration": "PT9.090735774S", "enqueuedAt": "2021-09-08T09:34:16.036101Z", "startedAt": "2021-09-08T09:34:16.261191226Z", "finishedAt": "2021-09-08T09:34:25.351927Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -400,7 +400,7 @@ async fn import_dump_v1_rubygems_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks["results"][0], - json!({"uid": 92, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT1.487793839S", "enqueuedAt": "2021-09-08T09:27:01.465296Z", "startedAt": "2021-09-08T09:28:44.882177161Z", "finishedAt": "2021-09-08T09:28:46.369971Z"}) + json!({"uid": 92, "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT1.487793839S", "enqueuedAt": "2021-09-08T09:27:01.465296Z", "startedAt": "2021-09-08T09:28:44.882177161Z", "finishedAt": "2021-09-08T09:28:46.369971Z"}) ); // finally we're just going to check that we can still get a few documents by id @@ -535,7 +535,7 @@ async fn import_dump_v2_movie_raw() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{"uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) + json!({ "results": [{"uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -682,7 +682,7 @@ async fn import_dump_v2_movie_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{ "uid": 1, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) + json!({ "results": [{ "uid": 1, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -828,7 +828,7 @@ async fn import_dump_v2_rubygems_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks["results"][0], - json!({"uid": 92, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) + json!({"uid": 92, "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) ); // finally we're just going to check that we can still get a few documents by id @@ -963,7 +963,7 @@ async fn import_dump_v3_movie_raw() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{"uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) + json!({ "results": [{"uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit": 20, "from": 0, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -1110,7 +1110,7 @@ async fn import_dump_v3_movie_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{ "uid": 1, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) + json!({ "results": [{ "uid": 1, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) ); // finally we're just going to check that we can["results"] still get a few documents by id @@ -1256,7 +1256,7 @@ async fn import_dump_v3_rubygems_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks["results"][0], - json!({"uid": 92, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) + json!({"uid": 92, "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) ); // finally we're just going to check that we can still get a few documents by id @@ -1391,7 +1391,7 @@ async fn import_dump_v4_movie_raw() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{"uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit" : 20, "from": 0, "next": null }) + json!({ "results": [{"uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT41.751156S", "enqueuedAt": "2021-09-08T08:30:30.550282Z", "startedAt": "2021-09-08T08:30:30.553012Z", "finishedAt": "2021-09-08T08:31:12.304168Z" }], "total": 1, "limit" : 20, "from": 0, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -1538,7 +1538,7 @@ async fn import_dump_v4_movie_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks, - json!({ "results": [{ "uid": 1, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) + json!({ "results": [{ "uid": 1, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", "canceledBy": null, "details": { "displayedAttributes": ["title", "genres", "overview", "poster", "release_date"], "searchableAttributes": ["title", "overview"], "filterableAttributes": ["genres"], "stopWords": ["of", "the"] }, "error": null, "duration": "PT37.488777S", "enqueuedAt": "2021-09-08T08:24:02.323444Z", "startedAt": "2021-09-08T08:24:02.324145Z", "finishedAt": "2021-09-08T08:24:39.812922Z" }, { "uid": 0, "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": { "receivedDocuments": 0, "indexedDocuments": 31944 }, "error": null, "duration": "PT39.941318S", "enqueuedAt": "2021-09-08T08:21:14.742672Z", "startedAt": "2021-09-08T08:21:14.750166Z", "finishedAt": "2021-09-08T08:21:54.691484Z" }], "total": 2, "limit": 20, "from": 1, "next": null }) ); // finally we're just going to check that we can still get a few documents by id @@ -1684,7 +1684,7 @@ async fn import_dump_v4_rubygems_with_settings() { snapshot!(code, @"200 OK"); assert_eq!( tasks["results"][0], - json!({ "uid": 92, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) + json!({ "uid": 92, "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", "canceledBy": null, "details": {"receivedDocuments": 0, "indexedDocuments": 1042}, "error": null, "duration": "PT14.034672S", "enqueuedAt": "2021-09-08T08:40:31.390775Z", "startedAt": "2021-09-08T08:51:39.060642Z", "finishedAt": "2021-09-08T08:51:53.095314Z"}) ); // finally we're just going to check that we can still get a few documents by id diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/1.snap index 2004eb036..a9e7be539 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/1.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "pets", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/2.snap index 8405a0461..ed457d9a6 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/generate_and_import_dump_containing_vectors/2.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "pets", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/1.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/2.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/3.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/4.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/5.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/6.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/7.snap index 7227fd4cc..b79ce068c 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_raw/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/1.snap index d22c13b72..bbda115f4 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/2.snap index d22c13b72..bbda115f4 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/3.snap index b49f68a59..612a922d2 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/4.snap index b49f68a59..612a922d2 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/5.snap index b49f68a59..612a922d2 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/6.snap index b49f68a59..612a922d2 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/7.snap index b49f68a59..612a922d2 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_movie_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/1.snap index beb25ce95..e1887a1f8 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/2.snap index add41439f..b085d78a4 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/3.snap index c9e368061..b793e4eb9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/4.snap index c9e368061..b793e4eb9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/5.snap index c9e368061..b793e4eb9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/6.snap index c9e368061..b793e4eb9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/7.snap index c9e368061..b793e4eb9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v1_rubygems_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/1.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/2.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/3.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/4.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/5.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/6.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/7.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_raw/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/1.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/2.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/3.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/4.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/5.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/6.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/7.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_movie_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/1.snap index 92613ce34..6ecf9200e 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/2.snap index bfef698e1..3ed8929c1 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/3.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/4.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/5.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/6.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/7.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v2_rubygems_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/1.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/2.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/3.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/4.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/5.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/6.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/7.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_raw/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/1.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/2.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/3.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/4.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/5.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/6.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/7.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_movie_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/1.snap index 92613ce34..6ecf9200e 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/2.snap index bfef698e1..3ed8929c1 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/3.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/4.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/5.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/6.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/7.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v3_rubygems_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/1.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/2.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/3.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/4.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/5.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/6.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/7.snap index 33f1b46c5..93a2938a9 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_raw/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/1.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/2.snap index 6acf1f564..ec5c69801 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/3.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/4.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/5.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/6.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/7.snap index 22fad9f58..0b8da54bf 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_movie_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "indexUID", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/1.snap index 92613ce34..6ecf9200e 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/2.snap index bfef698e1..3ed8929c1 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/3.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/4.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/5.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/6.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/7.snap index 3fa18f512..4005cdfed 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v4_rubygems_with_settings/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 92, + "batchUid": null, "indexUid": "rubygems", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/1.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/1.snap index b8c0d07b1..2de02953d 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/1.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/1.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 0, + "batchUid": null, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/2.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/2.snap index b31fb744f..dac7f08f7 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/2.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/2.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 1, + "batchUid": null, "indexUid": "test2", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/3.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/3.snap index 082cc97ee..319b6b229 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/3.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/3.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 4, + "batchUid": 0, "indexUid": null, "status": "succeeded", "type": "dumpCreation", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/4.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/4.snap index 54e8f84bf..19c8fc8aa 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/4.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/4.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 2, + "batchUid": null, "indexUid": "test", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/5.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/5.snap index 082cc97ee..319b6b229 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/5.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/5.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 4, + "batchUid": 0, "indexUid": null, "status": "succeeded", "type": "dumpCreation", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/6.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/6.snap index 082cc97ee..319b6b229 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/6.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/6.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 4, + "batchUid": 0, "indexUid": null, "status": "succeeded", "type": "dumpCreation", diff --git a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/7.snap b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/7.snap index 082cc97ee..319b6b229 100644 --- a/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/7.snap +++ b/crates/meilisearch/tests/dumps/snapshots/mod.rs/import_dump_v5/7.snap @@ -1,10 +1,11 @@ --- -source: meilisearch/tests/dumps/mod.rs +source: crates/meilisearch/tests/dumps/mod.rs --- { "results": [ { "uid": 4, + "batchUid": 0, "indexUid": null, "status": "succeeded", "type": "dumpCreation", diff --git a/crates/meilisearch/tests/search/snapshots/distinct.rs/distinct_at_search_time/succeed.snap b/crates/meilisearch/tests/search/snapshots/distinct.rs/distinct_at_search_time/succeed.snap index 64e48b6a5..ea55d9c61 100644 --- a/crates/meilisearch/tests/search/snapshots/distinct.rs/distinct_at_search_time/succeed.snap +++ b/crates/meilisearch/tests/search/snapshots/distinct.rs/distinct_at_search_time/succeed.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/search/distinct.rs +source: crates/meilisearch/tests/search/distinct.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "tamo", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/snapshot/mod.rs b/crates/meilisearch/tests/snapshot/mod.rs index 0008993fe..b4454a7f2 100644 --- a/crates/meilisearch/tests/snapshot/mod.rs +++ b/crates/meilisearch/tests/snapshot/mod.rs @@ -151,6 +151,7 @@ async fn perform_on_demand_snapshot() { snapshot!(json_string!(task, { ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]", ".duration" => "[duration]" }), @r###" { "uid": 4, + "batchUid": 4, "indexUid": null, "status": "succeeded", "type": "snapshotCreation", diff --git a/crates/meilisearch/tests/swap_indexes/mod.rs b/crates/meilisearch/tests/swap_indexes/mod.rs index 7f2b1623c..646f773d8 100644 --- a/crates/meilisearch/tests/swap_indexes/mod.rs +++ b/crates/meilisearch/tests/swap_indexes/mod.rs @@ -24,6 +24,7 @@ async fn swap_indexes() { "results": [ { "uid": 1, + "batchUid": 1, "indexUid": "b", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -40,6 +41,7 @@ async fn swap_indexes() { }, { "uid": 0, + "batchUid": 0, "indexUid": "a", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -76,6 +78,7 @@ async fn swap_indexes() { "results": [ { "uid": 2, + "batchUid": 2, "indexUid": null, "status": "succeeded", "type": "indexSwap", @@ -98,6 +101,7 @@ async fn swap_indexes() { }, { "uid": 1, + "batchUid": 1, "indexUid": "a", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -114,6 +118,7 @@ async fn swap_indexes() { }, { "uid": 0, + "batchUid": 0, "indexUid": "b", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -164,6 +169,7 @@ async fn swap_indexes() { "results": [ { "uid": 4, + "batchUid": 4, "indexUid": "d", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -180,6 +186,7 @@ async fn swap_indexes() { }, { "uid": 3, + "batchUid": 3, "indexUid": "c", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -226,6 +233,7 @@ async fn swap_indexes() { "results": [ { "uid": 5, + "batchUid": 5, "indexUid": null, "status": "succeeded", "type": "indexSwap", @@ -254,6 +262,7 @@ async fn swap_indexes() { }, { "uid": 4, + "batchUid": 4, "indexUid": "c", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -270,6 +279,7 @@ async fn swap_indexes() { }, { "uid": 3, + "batchUid": 3, "indexUid": "d", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -286,6 +296,7 @@ async fn swap_indexes() { }, { "uid": 2, + "batchUid": 2, "indexUid": null, "status": "succeeded", "type": "indexSwap", @@ -308,6 +319,7 @@ async fn swap_indexes() { }, { "uid": 1, + "batchUid": 1, "indexUid": "b", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -324,6 +336,7 @@ async fn swap_indexes() { }, { "uid": 0, + "batchUid": 0, "indexUid": "a", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/tasks/mod.rs b/crates/meilisearch/tests/tasks/mod.rs index 8cff3c447..fc05ee4ca 100644 --- a/crates/meilisearch/tests/tasks/mod.rs +++ b/crates/meilisearch/tests/tasks/mod.rs @@ -286,6 +286,7 @@ async fn test_summarized_document_addition_or_update() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -310,6 +311,7 @@ async fn test_summarized_document_addition_or_update() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -339,6 +341,7 @@ async fn test_summarized_delete_documents_by_batch() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "failed", "type": "documentDeletion", @@ -370,6 +373,7 @@ async fn test_summarized_delete_documents_by_batch() { @r###" { "uid": 2, + "batchUid": 2, "indexUid": "test", "status": "succeeded", "type": "documentDeletion", @@ -401,6 +405,7 @@ async fn test_summarized_delete_documents_by_filter() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "failed", "type": "documentDeletion", @@ -432,6 +437,7 @@ async fn test_summarized_delete_documents_by_filter() { @r###" { "uid": 2, + "batchUid": 2, "indexUid": "test", "status": "failed", "type": "documentDeletion", @@ -463,6 +469,7 @@ async fn test_summarized_delete_documents_by_filter() { @r###" { "uid": 4, + "batchUid": 4, "indexUid": "test", "status": "succeeded", "type": "documentDeletion", @@ -493,6 +500,7 @@ async fn test_summarized_delete_document_by_id() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "failed", "type": "documentDeletion", @@ -524,6 +532,7 @@ async fn test_summarized_delete_document_by_id() { @r###" { "uid": 2, + "batchUid": 2, "indexUid": "test", "status": "succeeded", "type": "documentDeletion", @@ -566,6 +575,7 @@ async fn test_summarized_settings_update() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "succeeded", "type": "settingsUpdate", @@ -604,6 +614,7 @@ async fn test_summarized_index_creation() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "succeeded", "type": "indexCreation", @@ -627,6 +638,7 @@ async fn test_summarized_index_creation() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "failed", "type": "indexCreation", @@ -658,6 +670,7 @@ async fn test_summarized_index_deletion() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "failed", "type": "indexDeletion", @@ -688,6 +701,7 @@ async fn test_summarized_index_deletion() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -710,6 +724,7 @@ async fn test_summarized_index_deletion() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "succeeded", "type": "indexDeletion", @@ -732,6 +747,7 @@ async fn test_summarized_index_deletion() { @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "test", "status": "failed", "type": "indexDeletion", @@ -766,6 +782,7 @@ async fn test_summarized_index_update() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": "test", "status": "failed", "type": "indexUpdate", @@ -794,6 +811,7 @@ async fn test_summarized_index_update() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": "test", "status": "failed", "type": "indexUpdate", @@ -825,6 +843,7 @@ async fn test_summarized_index_update() { @r###" { "uid": 3, + "batchUid": 3, "indexUid": "test", "status": "succeeded", "type": "indexUpdate", @@ -848,6 +867,7 @@ async fn test_summarized_index_update() { @r###" { "uid": 4, + "batchUid": 4, "indexUid": "test", "status": "succeeded", "type": "indexUpdate", @@ -879,6 +899,7 @@ async fn test_summarized_index_swap() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": null, "status": "failed", "type": "indexSwap", @@ -920,6 +941,7 @@ async fn test_summarized_index_swap() { @r###" { "uid": 3, + "batchUid": 3, "indexUid": null, "status": "succeeded", "type": "indexSwap", @@ -958,6 +980,7 @@ async fn test_summarized_task_cancelation() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": null, "status": "succeeded", "type": "taskCancelation", @@ -991,6 +1014,7 @@ async fn test_summarized_task_deletion() { @r###" { "uid": 1, + "batchUid": 1, "indexUid": null, "status": "succeeded", "type": "taskDeletion", @@ -1020,6 +1044,7 @@ async fn test_summarized_dump_creation() { @r###" { "uid": 0, + "batchUid": 0, "indexUid": null, "status": "succeeded", "type": "dumpCreation", diff --git a/crates/meilisearch/tests/tasks/webhook.rs b/crates/meilisearch/tests/tasks/webhook.rs index b01ef3d5a..b18002eb7 100644 --- a/crates/meilisearch/tests/tasks/webhook.rs +++ b/crates/meilisearch/tests/tasks/webhook.rs @@ -8,12 +8,12 @@ use actix_http::body::MessageBody; use actix_web::dev::{ServiceFactory, ServiceResponse}; use actix_web::web::{Bytes, Data}; use actix_web::{post, App, HttpRequest, HttpResponse, HttpServer}; -use meili_snap::{json_string, snapshot}; +use meili_snap::snapshot; use meilisearch::Opt; use tokio::sync::mpsc; use url::Url; -use crate::common::{default_settings, Server}; +use crate::common::{self, default_settings, Server}; use crate::json; #[post("/")] @@ -97,11 +97,11 @@ async fn test_basic_webhook() { } nb_tasks += 1; let json: serde_json::Value = serde_json::from_str(json).unwrap(); - snapshot!( - json_string!(json, { ".uid" => "[uid]", ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }), + snapshot!(common::Value(json), @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "tamo", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/vector/binary_quantized.rs b/crates/meilisearch/tests/vector/binary_quantized.rs index d3fe3c824..560c4e2f2 100644 --- a/crates/meilisearch/tests/vector/binary_quantized.rs +++ b/crates/meilisearch/tests/vector/binary_quantized.rs @@ -303,6 +303,7 @@ async fn try_to_disable_binary_quantization() { snapshot!(ret, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/vector/mod.rs b/crates/meilisearch/tests/vector/mod.rs index 47d0c1051..828f72c5e 100644 --- a/crates/meilisearch/tests/vector/mod.rs +++ b/crates/meilisearch/tests/vector/mod.rs @@ -240,6 +240,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -269,6 +270,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -299,6 +301,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -328,6 +331,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -357,6 +361,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -386,6 +391,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -427,6 +433,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -455,6 +462,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -483,6 +491,7 @@ async fn user_provided_embeddings_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -523,6 +532,7 @@ async fn user_provided_vectors_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -552,6 +562,7 @@ async fn user_provided_vectors_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -581,6 +592,7 @@ async fn user_provided_vectors_error() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/vector/openai.rs b/crates/meilisearch/tests/vector/openai.rs index 04c068c40..9fae810f9 100644 --- a/crates/meilisearch/tests/vector/openai.rs +++ b/crates/meilisearch/tests/vector/openai.rs @@ -365,6 +365,7 @@ async fn it_works() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -595,6 +596,7 @@ async fn tokenize_long_text() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -651,6 +653,7 @@ async fn bad_api_key() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -683,6 +686,7 @@ async fn bad_api_key() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -727,6 +731,7 @@ async fn bad_api_key() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -796,6 +801,7 @@ async fn bad_model() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -873,6 +879,7 @@ async fn bad_dimensions() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -980,6 +987,7 @@ async fn smaller_dimensions() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1211,6 +1219,7 @@ async fn small_embedding_model() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1441,6 +1450,7 @@ async fn legacy_embedding_model() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1672,6 +1682,7 @@ async fn it_still_works() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/vector/rest.rs b/crates/meilisearch/tests/vector/rest.rs index 2748d0846..2bf6f2a46 100644 --- a/crates/meilisearch/tests/vector/rest.rs +++ b/crates/meilisearch/tests/vector/rest.rs @@ -922,6 +922,7 @@ async fn bad_settings() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -967,6 +968,7 @@ async fn bad_settings() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1016,6 +1018,7 @@ async fn add_vector_and_user_provided() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1112,6 +1115,7 @@ async fn server_returns_bad_request() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1152,6 +1156,7 @@ async fn server_returns_bad_request() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "settingsUpdate", @@ -1185,6 +1190,7 @@ async fn server_returns_bad_request() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "documentAdditionOrUpdate", @@ -1229,6 +1235,7 @@ async fn server_returns_bad_response() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1282,6 +1289,7 @@ async fn server_returns_bad_response() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1337,6 +1345,7 @@ async fn server_returns_bad_response() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1392,6 +1401,7 @@ async fn server_returns_bad_response() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1457,6 +1467,7 @@ async fn server_returns_bad_response() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1524,6 +1535,7 @@ async fn server_returns_multiple() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1629,6 +1641,7 @@ async fn server_single_input_returns_in_array() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1734,6 +1747,7 @@ async fn server_raw() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -1831,6 +1845,7 @@ async fn server_custom_header() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1870,6 +1885,7 @@ async fn server_custom_header() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", @@ -1912,6 +1928,7 @@ async fn server_custom_header() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "settingsUpdate", @@ -1957,6 +1974,7 @@ async fn searchable_reindex() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "settingsUpdate", @@ -1993,6 +2011,7 @@ async fn searchable_reindex() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", @@ -2021,6 +2040,7 @@ async fn searchable_reindex() { snapshot!(task, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "failed", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/vector/settings.rs b/crates/meilisearch/tests/vector/settings.rs index ed45913a8..027c55219 100644 --- a/crates/meilisearch/tests/vector/settings.rs +++ b/crates/meilisearch/tests/vector/settings.rs @@ -91,6 +91,7 @@ async fn update_embedder() { snapshot!(ret, @r###" { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "settingsUpdate", diff --git a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-added.snap b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-added.snap index c4f1c0b25..709dfeae0 100644 --- a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-added.snap +++ b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-added.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/vector/mod.rs +source: crates/meilisearch/tests/vector/mod.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-deleted.snap b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-deleted.snap index c4f1c0b25..709dfeae0 100644 --- a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-deleted.snap +++ b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/document-deleted.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/vector/mod.rs +source: crates/meilisearch/tests/vector/mod.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "documentAdditionOrUpdate", diff --git a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/settings-processed.snap b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/settings-processed.snap index 08dbe3ee0..c8bad0070 100644 --- a/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/settings-processed.snap +++ b/crates/meilisearch/tests/vector/snapshots/mod.rs/add_remove_one_vector_4588/settings-processed.snap @@ -1,8 +1,9 @@ --- -source: meilisearch/tests/vector/mod.rs +source: crates/meilisearch/tests/vector/mod.rs --- { "uid": "[uid]", + "batchUid": "[batch_uid]", "indexUid": "doggo", "status": "succeeded", "type": "settingsUpdate", From a1251c3c83dfdc27754f0e2de00a74c2e73e1c69 Mon Sep 17 00:00:00 2001 From: Tamo Date: Thu, 14 Nov 2024 17:31:02 +0100 Subject: [PATCH 02/22] Implements the get all batches route with filters working --- crates/index-scheduler/src/error.rs | 5 + crates/index-scheduler/src/insta_snapshot.rs | 62 ++++- crates/index-scheduler/src/lib.rs | 237 +++++++++++++++--- .../initial_tasks_enqueued.snap | 22 +- .../aborted_indexation.snap | 31 ++- .../first_task_processed.snap | 31 ++- ...rocessing_second_task_cancel_enqueued.snap | 31 ++- .../after_dump_register.snap | 22 +- .../cancel_registered.snap | 22 +- .../aborted_indexation.snap | 22 +- .../cancel_task_registered.snap | 22 +- .../initial_task_processing.snap | 22 +- .../registered_the_first_task.snap | 22 +- .../cancel_processed.snap | 38 ++- .../initial_task_processed.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../all_tasks_processed.snap | 64 ++++- .../document_addition/after_register.snap | 22 +- .../after_the_batch_creation.snap | 22 +- .../once_everything_is_processed.snap | 31 ++- .../after_processing_the_batch.snap | 35 ++- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../before_index_creation.snap | 31 ++- .../both_task_succeeded.snap | 42 +++- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../registered_the_third_task.snap | 22 +- .../1.snap | 22 +- .../2.snap | 35 ++- .../after_failing_the_deletion.snap | 31 ++- .../after_last_successful_addition.snap | 39 ++- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../document_addition_batch_created.snap | 22 +- .../document_addition_failed.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../after_adding_the_documents.snap | 37 ++- .../after_adding_the_settings.snap | 30 ++- .../after_removing_the_documents.snap | 52 +++- .../registered_the_document_deletions.snap | 37 ++- ...red_the_setting_and_document_addition.snap | 21 +- .../after_register.snap | 22 +- .../index_creation_failed.snap | 31 ++- .../after_batch_succeeded.snap | 22 +- .../after_failing_to_commit.snap | 22 +- ...eeded_but_index_scheduler_not_updated.snap | 22 +- .../registered_the_first_task.snap | 22 +- .../task_successfully_processed.snap | 31 ++- .../Intel to kefir succeeds.snap | 43 +++- .../lib.rs/import_vectors/Intel to kefir.snap | 37 ++- .../import_vectors/adding Intel succeeds.snap | 37 ++- .../import_vectors/after adding Intel.snap | 30 ++- ...ter_registering_settings_task_vectors.snap | 21 +- .../settings_update_processed_vectors.snap | 30 ++- .../after_batch_creation.snap | 22 +- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../registered_the_third_task.snap | 22 +- .../index_creation_failed.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../processed_the_first_task.snap | 31 ++- .../processed_the_second_task.snap | 38 ++- .../processed_the_third_task.snap | 45 +++- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../registered_the_third_task.snap | 22 +- .../first.snap | 31 ++- .../fourth.snap | 50 +++- .../registered_the_first_task.snap | 22 +- .../registered_the_fourth_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../registered_the_third_task.snap | 22 +- .../second.snap | 38 ++- .../third.snap | 44 +++- .../processed_all_tasks.snap | 45 +++- .../registered_the_first_task.snap | 22 +- .../registered_the_second_task.snap | 22 +- .../registered_the_third_task.snap | 22 +- .../lib.rs/query_tasks_simple/end.snap | 46 +++- .../lib.rs/query_tasks_simple/start.snap | 22 +- .../query_tasks_special_rules/start.snap | 22 +- ...everything_is_successfully_registered.snap | 22 +- .../lib.rs/swap_indexes/create_a.snap | 31 ++- .../lib.rs/swap_indexes/create_b.snap | 38 ++- .../lib.rs/swap_indexes/create_c.snap | 45 +++- .../lib.rs/swap_indexes/create_d.snap | 52 +++- .../swap_indexes/first_swap_processed.snap | 59 ++++- .../swap_indexes/first_swap_registered.snap | 52 +++- .../swap_indexes/second_swap_processed.snap | 65 ++++- .../third_empty_swap_processed.snap | 71 +++++- .../swap_indexes/two_swaps_registered.snap | 52 +++- .../after_the_index_creation.snap | 52 +++- .../first_swap_failed.snap | 62 ++++- .../initial_tasks_processed.snap | 52 +++- .../initial_tasks_enqueued.snap | 22 +- .../initial_tasks_processed.snap | 31 ++- .../task_deletion_processed.snap | 39 ++- .../after_registering_the_task_deletion.snap | 31 ++- .../initial_tasks_enqueued.snap | 22 +- .../initial_tasks_processed.snap | 31 ++- .../task_deletion_processed.snap | 36 ++- .../initial_tasks_enqueued.snap | 22 +- .../task_deletion_done.snap | 30 ++- .../task_deletion_enqueued.snap | 22 +- .../task_deletion_processing.snap | 22 +- .../after_the_second_task_deletion.snap | 4 +- .../everything_has_been_processed.snap | 3 +- .../task_deletion_have_been_enqueued.snap | 7 +- .../task_deletion_have_been_processed.snap | 5 +- .../task_queue_is_full.snap | 6 +- .../task_deletion_have_not_been_enqueued.snap | 6 +- .../task_queue_is_full.snap | 6 +- .../after_processing_the_10_tasks.snap | 57 +++-- .../after_registering_the_10_tasks.snap | 31 ++- .../processed_the_first_task.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../after_registering_the_10_tasks.snap | 31 ++- .../all_tasks_processed.snap | 92 +++++-- .../five_tasks_processed.snap | 62 ++++- .../processed_the_first_task.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../after_processing_the_10_tasks.snap | 50 +++- .../after_registering_the_10_tasks.snap | 22 +- .../after_registering_the_10_tasks.snap | 22 +- .../all_tasks_processed.snap | 85 ++++++- .../five_tasks_processed.snap | 55 +++- .../after_registering_the_10_tasks.snap | 22 +- .../all_tasks_processed.snap | 55 +++- .../only_first_task_failed.snap | 31 ++- .../after_registering_the_10_tasks.snap | 31 ++- .../all_tasks_processed.snap | 57 +++-- .../processed_the_first_task.snap | 31 ++- .../registered_the_first_task.snap | 22 +- .../after_registering_the_5_tasks.snap | 22 +- .../fifth_task_succeeds.snap | 53 +++- .../first_and_second_task_fails.snap | 34 ++- .../fourth_task_fails.snap | 47 +++- .../third_task_succeeds.snap | 41 ++- .../after_registering_the_3_tasks.snap | 22 +- .../only_first_task_succeed.snap | 31 ++- .../second_task_fails.snap | 38 ++- .../third_task_fails.snap | 44 +++- .../after_registering_the_3_tasks.snap | 22 +- .../only_first_task_succeed.snap | 31 ++- .../second_and_third_tasks_fails.snap | 38 ++- .../after_registering_the_6_tasks.snap | 22 +- .../all_other_tasks_succeeds.snap | 55 +++- .../first_task_fails.snap | 31 ++- .../second_task_fails.snap | 37 ++- .../third_task_succeeds.snap | 44 +++- .../after_registering_the_6_tasks.snap | 22 +- .../all_other_tasks_succeeds.snap | 55 +++- .../first_task_succeed.snap | 31 ++- .../second_task_fails.snap | 38 ++- .../third_task_succeeds.snap | 44 +++- .../lib.rs/test_document_replace/1.snap | 22 +- .../lib.rs/test_document_replace/2.snap | 50 +++- .../after_registering_the_10_tasks.snap | 22 +- .../all_tasks_processed.snap | 85 ++++++- .../five_tasks_processed.snap | 55 +++- .../lib.rs/test_document_update/1.snap | 22 +- .../lib.rs/test_document_update/2.snap | 50 +++- .../after_registering_the_10_tasks.snap | 22 +- .../all_tasks_processed.snap | 85 ++++++- .../five_tasks_processed.snap | 55 +++- .../after_registering_the_10_tasks.snap | 22 +- .../all_tasks_processed.snap | 85 ++++++- .../five_tasks_processed.snap | 55 +++- .../after_registering_settings_task.snap | 21 +- .../settings_update_processed.snap | 30 ++- .../registered_a_task.snap | 22 +- crates/index-scheduler/src/utils.rs | 192 +++++++++++++- crates/meilisearch-types/src/batch_view.rs | 30 +++ crates/meilisearch-types/src/error.rs | 1 + crates/meilisearch-types/src/lib.rs | 1 + crates/meilisearch/src/routes/batches.rs | 54 +++- crates/meilisearch/src/routes/mod.rs | 1 + crates/meilisearch/src/routes/tasks.rs | 2 +- 179 files changed, 5362 insertions(+), 849 deletions(-) create mode 100644 crates/meilisearch-types/src/batch_view.rs diff --git a/crates/index-scheduler/src/error.rs b/crates/index-scheduler/src/error.rs index 434764677..336c0b732 100644 --- a/crates/index-scheduler/src/error.rs +++ b/crates/index-scheduler/src/error.rs @@ -1,5 +1,6 @@ use std::fmt::Display; +use meilisearch_types::batches::BatchId; use meilisearch_types::error::{Code, ErrorCode}; use meilisearch_types::tasks::{Kind, Status}; use meilisearch_types::{heed, milli}; @@ -108,6 +109,8 @@ pub enum Error { InvalidIndexUid { index_uid: String }, #[error("Task `{0}` not found.")] TaskNotFound(TaskId), + #[error("Batch `{0}` not found.")] + BatchNotFound(BatchId), #[error("Query parameters to filter the tasks to delete are missing. Available query parameters are: `uids`, `indexUids`, `statuses`, `types`, `canceledBy`, `beforeEnqueuedAt`, `afterEnqueuedAt`, `beforeStartedAt`, `afterStartedAt`, `beforeFinishedAt`, `afterFinishedAt`.")] TaskDeletionWithEmptyQuery, #[error("Query parameters to filter the tasks to cancel are missing. Available query parameters are: `uids`, `indexUids`, `statuses`, `types`, `canceledBy`, `beforeEnqueuedAt`, `afterEnqueuedAt`, `beforeStartedAt`, `afterStartedAt`, `beforeFinishedAt`, `afterFinishedAt`.")] @@ -181,6 +184,7 @@ impl Error { | Error::InvalidTaskCanceledBy { .. } | Error::InvalidIndexUid { .. } | Error::TaskNotFound(_) + | Error::BatchNotFound(_) | Error::TaskDeletionWithEmptyQuery | Error::TaskCancelationWithEmptyQuery | Error::AbortedTask @@ -226,6 +230,7 @@ impl ErrorCode for Error { Error::InvalidTaskCanceledBy { .. } => Code::InvalidTaskCanceledBy, Error::InvalidIndexUid { .. } => Code::InvalidIndexUid, Error::TaskNotFound(_) => Code::TaskNotFound, + Error::BatchNotFound(_) => Code::TaskNotFound, Error::TaskDeletionWithEmptyQuery => Code::MissingTaskFilters, Error::TaskCancelationWithEmptyQuery => Code::MissingTaskFilters, // TODO: not sure of the Code to use diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index f2b9df555..4cf639889 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -1,6 +1,7 @@ use std::collections::BTreeSet; use std::fmt::Write; +use meilisearch_types::batches::Batch; use meilisearch_types::heed::types::{SerdeBincode, SerdeJson, Str}; use meilisearch_types::heed::{Database, RoTxn}; use meilisearch_types::milli::{CboRoaringBitmapCodec, RoaringBitmapCodec, BEU32}; @@ -64,10 +65,10 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { let mut snap = String::new(); - let processing_tasks = processing_tasks.read().unwrap().processing.clone(); + let processing = processing_tasks.read().unwrap().clone(); snap.push_str(&format!("### Autobatching Enabled = {autobatching_enabled}\n")); - snap.push_str("### Processing Tasks:\n"); - snap.push_str(&snapshot_bitmap(&processing_tasks)); + snap.push_str(&format!("### Processing batch {:?}:\n", processing.batch_id)); + snap.push_str(&snapshot_bitmap(&processing.processing)); snap.push_str("\n----------------------------------------------------------------------\n"); snap.push_str("### All Tasks:\n"); @@ -106,6 +107,38 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { snap.push_str(&snapshot_date_db(&rtxn, *finished_at)); snap.push_str("----------------------------------------------------------------------\n"); + snap.push_str("### All Batches:\n"); + snap.push_str(&snapshot_all_batches(&rtxn, *all_batches)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Status:\n"); + snap.push_str(&snapshot_status(&rtxn, *batch_status)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Kind:\n"); + snap.push_str(&snapshot_kind(&rtxn, *batch_kind)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Index Tasks:\n"); + snap.push_str(&snapshot_index_tasks(&rtxn, *batch_index_tasks)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Canceled By:\n"); + snap.push_str(&snapshot_canceled_by(&rtxn, *batch_canceled_by)); + snap.push_str("\n----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Enqueued At:\n"); + snap.push_str(&snapshot_date_db(&rtxn, *batch_enqueued_at)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Started At:\n"); + snap.push_str(&snapshot_date_db(&rtxn, *batch_started_at)); + snap.push_str("----------------------------------------------------------------------\n"); + + snap.push_str("### Batches Finished At:\n"); + snap.push_str(&snapshot_date_db(&rtxn, *batch_finished_at)); + snap.push_str("----------------------------------------------------------------------\n"); + snap.push_str("### File Store:\n"); snap.push_str(&snapshot_file_store(file_store)); snap.push_str("\n----------------------------------------------------------------------\n"); @@ -143,6 +176,16 @@ pub fn snapshot_all_tasks(rtxn: &RoTxn, db: Database>) -> snap } +pub fn snapshot_all_batches(rtxn: &RoTxn, db: Database>) -> String { + let mut snap = String::new(); + let iter = db.iter(rtxn).unwrap(); + for next in iter { + let (batch_id, batch) = next.unwrap(); + snap.push_str(&format!("{batch_id} {}\n", snapshot_batch(&batch))); + } + snap +} + pub fn snapshot_date_db(rtxn: &RoTxn, db: Database) -> String { let mut snap = String::new(); let iter = db.iter(rtxn).unwrap(); @@ -287,6 +330,19 @@ pub fn snapshot_canceled_by(rtxn: &RoTxn, db: Database String { + let mut snap = String::new(); + let Batch { uid, started_at, finished_at } = batch; + if let Some(finished_at) = finished_at { + assert!(finished_at > started_at); + } + snap.push('{'); + snap.push_str(&format!("uid: {uid}, ")); + snap.push('}'); + snap +} + pub fn snapshot_index_mapper(rtxn: &RoTxn, mapper: &IndexMapper) -> String { let mut s = String::new(); let names = mapper.index_names(rtxn).unwrap(); diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 855dd8026..78bf1268b 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -71,7 +71,7 @@ use utils::{filter_out_references_to_newer_tasks, keep_tasks_within_datetimes, m use uuid::Uuid; use crate::index_mapper::IndexMapper; -use crate::utils::{check_index_swap_validity, clamp_to_page_size}; +use crate::utils::{check_index_swap_validity, clamp_to_page_size, CachedBatch}; pub(crate) type BEI128 = I128; @@ -192,9 +192,12 @@ impl ProcessingTasks { } /// Set the processing tasks to an empty list - fn stop_processing(&mut self) -> RoaringBitmap { - self.batch_id = None; - std::mem::take(&mut self.processing) + fn stop_processing(&mut self) -> Self { + Self { + started_at: self.started_at, + batch_id: self.batch_id.take(), + processing: std::mem::take(&mut self.processing), + } } /// Returns `true` if there, at least, is one task that is currently processing that we must stop. @@ -532,13 +535,13 @@ impl IndexScheduler { let started_at = env.create_database(&mut wtxn, Some(db_name::STARTED_AT))?; let finished_at = env.create_database(&mut wtxn, Some(db_name::FINISHED_AT))?; - let batch_status = env.create_database(&mut wtxn, Some(db_name::STATUS))?; - let batch_kind = env.create_database(&mut wtxn, Some(db_name::KIND))?; - let batch_index_tasks = env.create_database(&mut wtxn, Some(db_name::INDEX_TASKS))?; - let batch_canceled_by = env.create_database(&mut wtxn, Some(db_name::CANCELED_BY))?; - let batch_enqueued_at = env.create_database(&mut wtxn, Some(db_name::ENQUEUED_AT))?; - let batch_started_at = env.create_database(&mut wtxn, Some(db_name::STARTED_AT))?; - let batch_finished_at = env.create_database(&mut wtxn, Some(db_name::FINISHED_AT))?; + let batch_status = env.create_database(&mut wtxn, Some(db_name::BATCH_STATUS))?; + let batch_kind = env.create_database(&mut wtxn, Some(db_name::BATCH_KIND))?; + let batch_index_tasks = env.create_database(&mut wtxn, Some(db_name::BATCH_INDEX_TASKS))?; + let batch_canceled_by = env.create_database(&mut wtxn, Some(db_name::BATCH_CANCELED_BY))?; + let batch_enqueued_at = env.create_database(&mut wtxn, Some(db_name::BATCH_ENQUEUED_AT))?; + let batch_started_at = env.create_database(&mut wtxn, Some(db_name::BATCH_STARTED_AT))?; + let batch_finished_at = env.create_database(&mut wtxn, Some(db_name::BATCH_FINISHED_AT))?; wtxn.commit()?; // allow unreachable_code to get rids of the warning in the case of a test build. @@ -923,6 +926,147 @@ impl IndexScheduler { Ok(tasks) } + /// Return the batch ids matched by the given query from the index scheduler's point of view. + pub(crate) fn get_batch_ids(&self, rtxn: &RoTxn, query: &Query) -> Result { + let ProcessingTasks { + started_at: started_at_processing, + processing: processing_batches, + batch_id, + } = self.processing_tasks.read().unwrap().clone(); + + let mut batches = self.all_batch_ids(rtxn)?; + + if let Some(from) = &query.from { + batches.remove_range(from.saturating_add(1)..); + } + + if let Some(status) = &query.statuses { + let mut status_batches = RoaringBitmap::new(); + for status in status { + // TODO: We can't retrieve anything around processing batches so we can get rid of a lot of code here + match status { + // special case for Processing batches + Status::Processing => { + if let Some(batch_id) = batch_id { + status_batches.insert(batch_id); + } + } + status => status_batches |= &self.get_batch_status(rtxn, *status)?, + }; + } + if !status.contains(&Status::Processing) { + batches -= &processing_batches; + } + batches &= status_batches; + } + + if let Some(uids) = &query.uids { + let uids = RoaringBitmap::from_iter(uids); + batches &= &uids; + } + + if let Some(canceled_by) = &query.canceled_by { + let mut all_canceled_batches = RoaringBitmap::new(); + for cancel_uid in canceled_by { + if let Some(canceled_by_uid) = self.batch_canceled_by.get(rtxn, cancel_uid)? { + all_canceled_batches |= canceled_by_uid; + } + } + + // if the canceled_by has been specified but no batch + // matches then we prefer matching zero than all tasks. + if all_canceled_batches.is_empty() { + return Ok(RoaringBitmap::new()); + } else { + batches &= all_canceled_batches; + } + } + + if let Some(kind) = &query.types { + let mut kind_batches = RoaringBitmap::new(); + for kind in kind { + kind_batches |= self.get_batch_kind(rtxn, *kind)?; + } + batches &= &kind_batches; + } + + if let Some(index) = &query.index_uids { + let mut index_batches = RoaringBitmap::new(); + for index in index { + index_batches |= self.index_batches(rtxn, index)?; + } + batches &= &index_batches; + } + + // For the started_at filter, we need to treat the part of the batches that are processing from the part of the + // batches that are not processing. The non-processing ones are filtered normally while the processing ones + // are entirely removed unless the in-memory startedAt variable falls within the date filter. + // Once we have filtered the two subsets, we put them back together and assign it back to `batches`. + batches = { + let (mut filtered_non_processing_batches, mut filtered_processing_batches) = + (&batches - &processing_batches, &batches & &processing_batches); + + // special case for Processing batches + // A closure that clears the filtered_processing_batches if their started_at date falls outside the given bounds + let mut clear_filtered_processing_batches = + |start: Bound, end: Bound| { + let start = map_bound(start, |b| b.unix_timestamp_nanos()); + let end = map_bound(end, |b| b.unix_timestamp_nanos()); + let is_within_dates = RangeBounds::contains( + &(start, end), + &started_at_processing.unix_timestamp_nanos(), + ); + if !is_within_dates { + filtered_processing_batches.clear(); + } + }; + match (query.after_started_at, query.before_started_at) { + (None, None) => (), + (None, Some(before)) => { + clear_filtered_processing_batches(Bound::Unbounded, Bound::Excluded(before)) + } + (Some(after), None) => { + clear_filtered_processing_batches(Bound::Excluded(after), Bound::Unbounded) + } + (Some(after), Some(before)) => clear_filtered_processing_batches( + Bound::Excluded(after), + Bound::Excluded(before), + ), + }; + + keep_tasks_within_datetimes( + rtxn, + &mut filtered_non_processing_batches, + self.batch_started_at, + query.after_started_at, + query.before_started_at, + )?; + filtered_non_processing_batches | filtered_processing_batches + }; + + keep_tasks_within_datetimes( + rtxn, + &mut batches, + self.batch_enqueued_at, + query.after_enqueued_at, + query.before_enqueued_at, + )?; + + keep_tasks_within_datetimes( + rtxn, + &mut batches, + self.batch_finished_at, + query.after_finished_at, + query.before_finished_at, + )?; + + if let Some(limit) = query.limit { + batches = batches.into_iter().rev().take(limit as usize).collect(); + } + + Ok(batches) + } + /// The returned structure contains: /// 1. The name of the property being observed can be `statuses`, `types`, or `indexes`. /// 2. The name of the specific data related to the property can be `enqueued` for the `statuses`, `settingsUpdate` for the `types`, or the name of the index for the `indexes`, for example. @@ -1034,7 +1178,7 @@ impl IndexScheduler { /// 1. IndexSwap tasks are not publicly associated with any index, but they are associated /// with many indexes internally. /// 2. The user may not have the rights to access the tasks (internally) associated with all indexes. - pub fn get_task_ids_from_authorized_indexes( + pub fn get_batch_ids_from_authorized_indexes( &self, rtxn: &RoTxn, query: &Query, @@ -1063,12 +1207,12 @@ impl IndexScheduler { for result in all_indexes_iter { let (index, index_tasks) = result?; if !filters.is_index_authorized(index) { - tasks -= index_tasks; + batches -= index_tasks; } } } - Ok((tasks, total_tasks.len())) + Ok((batches, total_batches.len())) } /// Return the tasks matching the query from the user's point of view along @@ -1151,17 +1295,13 @@ impl IndexScheduler { if processing.is_empty() { Ok((ret.collect(), total)) } else { + // TODO: We must re-insert the current processing batch somewhere in some way Ok(( - ret.map(|task| { - if processing.contains(task.uid) { - Task { - status: Status::Processing, - batch_uid: batch_id, - started_at: Some(started_at), - ..task - } + ret.map(|batch| { + if processing.contains(batch.uid) { + Batch { started_at, ..batch } } else { - task + batch } }) .collect(), @@ -1374,6 +1514,7 @@ impl IndexScheduler { let mut wtxn = self.env.write_txn().map_err(Error::HeedTransaction)?; let finished_at = OffsetDateTime::now_utc(); + let mut current_batch = CachedBatch::new(batch_id, started_at, finished_at); match res { Ok(tasks) => { #[cfg(test)] @@ -1401,6 +1542,7 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; + current_batch.update(&task); } tracing::info!("A batch of tasks was successfully completed with {success} successful tasks and {failure} failed tasks."); } @@ -1463,18 +1605,15 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; + current_batch.update(&task); } } } - self.all_batches.put( - &mut wtxn, - &batch_id, - &Batch { uid: batch_id, started_at, finished_at: Some(finished_at) }, - )?; - let processed = self.processing_tasks.write().unwrap().stop_processing(); + self.write_batch(&mut wtxn, current_batch)?; + #[cfg(test)] self.maybe_fail(tests::FailureLocation::CommittingWtxn)?; @@ -1503,7 +1642,7 @@ impl IndexScheduler { })?; // We shouldn't crash the tick function if we can't send data to the webhook. - let _ = self.notify_webhook(&processed); + let _ = self.notify_webhook(&processed.processing); #[cfg(test)] self.breakpoint(Breakpoint::AfterProcessing); @@ -5256,7 +5395,7 @@ mod tests { snapshot!(task.uid, @"0"); snapshot!(snapshot_index_scheduler(&index_scheduler), @r###" ### Autobatching Enabled = true - ### Processing Tasks: + ### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -5279,6 +5418,23 @@ mod tests { ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- + ### All Batches: + ---------------------------------------------------------------------- + ### Batches Status: + ---------------------------------------------------------------------- + ### Batches Kind: + ---------------------------------------------------------------------- + ### Batches Index Tasks: + ---------------------------------------------------------------------- + ### Batches Canceled By: + + ---------------------------------------------------------------------- + ### Batches Enqueued At: + ---------------------------------------------------------------------- + ### Batches Started At: + ---------------------------------------------------------------------- + ### Batches Finished At: + ---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- @@ -5289,7 +5445,7 @@ mod tests { snapshot!(task.uid, @"12"); snapshot!(snapshot_index_scheduler(&index_scheduler), @r###" ### Autobatching Enabled = true - ### Processing Tasks: + ### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -5312,6 +5468,23 @@ mod tests { ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- + ### All Batches: + ---------------------------------------------------------------------- + ### Batches Status: + ---------------------------------------------------------------------- + ### Batches Kind: + ---------------------------------------------------------------------- + ### Batches Index Tasks: + ---------------------------------------------------------------------- + ### Batches Canceled By: + + ---------------------------------------------------------------------- + ### Batches Enqueued At: + ---------------------------------------------------------------------- + ### Batches Started At: + ---------------------------------------------------------------------- + ### Batches Finished At: + ---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap index 3d3830b29..e98f753ee 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap index 112cd597b..4dc48d1f0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(1): [1,] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "beavero", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "wolfo", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { matched_tasks: 3, canceled_tasks: None, original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} @@ -44,9 +44,32 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap index 16be0e4d5..f665ae94e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "beavero", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "wolfo", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- @@ -40,9 +40,32 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap index 46ccfcb8b..b68dd1feb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(1): [1,] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "beavero", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "wolfo", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { matched_tasks: 3, canceled_tasks: None, original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} @@ -43,9 +43,32 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap index ce0343975..f785eed48 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -29,7 +29,23 @@ enqueued [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap index 72ae58e00..808a3b662 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -32,7 +32,23 @@ enqueued [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap index a2187ab2b..6e3713ceb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -34,8 +34,24 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap index f65b5ee67..9cd11b76f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap index 8a3ad4661..bd03ada39 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap index 6873f8b56..a96abf42d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap index 36e47f569..756edc2f2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(0), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(0), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -40,7 +40,35 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"taskCancelation" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap index 028e03446..d0388328b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap index 6873f8b56..a96abf42d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap index c9a12c327..0d0ddd63d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} -2 {uid: 2, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "girafos", primary_key: None }} -3 {uid: 3, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} -4 {uid: 4, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "cattos" }} -5 {uid: 5, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "girafos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "girafos", primary_key: None }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "cattos" }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "girafos" }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -59,7 +59,53 @@ girafos: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] [timestamp] [5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,] +---------------------------------------------------------------------- +### Batches Kind: +"documentDeletion" [3,4,5,] +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +cattos [1,4,] +doggos [0,3,] +girafos [2,5,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap index c1869a475..189e84249 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap index 33d58eab6..333505b3c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap index b4a6da3af..6a445dd2f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap index b27288a0f..337f68862 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_document_ids: 2, deleted_documents: Some(2) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { received_document_ids: 2, deleted_documents: Some(2) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -37,7 +37,32 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Finished At: [timestamp] [0,1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"documentDeletion" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap index d26e62bff..60a3a9ad4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap index e0f371120..dfb0af950 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap index 97ba419a8..d629deb13 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { deleted_documents: None }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- @@ -40,8 +40,31 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap index fd96ee974..ccf2f375e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -41,7 +41,37 @@ doggos [0,1,2,] [timestamp] [0,] [timestamp] [1,2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"indexCreation" [0,] +"indexDeletion" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap index 1a29c1ac6..4d37e461d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap index 68ded1f0d..5599779ca 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap index 1601a6b25..05594e75a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -36,8 +36,24 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap index c200ce402..d27aa6637 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap index 7884dfe08..bfd425625 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -36,7 +36,32 @@ doggos [0,1,] ### Finished At: [timestamp] [0,1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"indexDeletion" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 1d4aa24e2..49cfb5558 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_document_ids: 2, deleted_documents: Some(0) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_document_ids: 2, deleted_documents: Some(0) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} 1 {uid: 1, status: enqueued, details: { received_documents: 3, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -36,8 +36,31 @@ doggos [0,1,] ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentDeletion" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index 0f9dfd3e6..24ea830aa 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_document_ids: 2, deleted_documents: Some(0) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} -1 {uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_document_ids: 2, deleted_documents: Some(0) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1", "2"] }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -40,7 +40,36 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [1,] +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"documentDeletion" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap index 5753db7e6..95911d88c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap index 0b6191f9e..805b45c09 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,8 +33,24 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap index 33d58eab6..333505b3c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index e66ffa567..6a46f7021 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -33,7 +33,30 @@ doggos [0,] ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap index c1869a475..189e84249 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap index 62e634bc5..57fb1ff22 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -39,6 +39,35 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap index 45065d8b1..c418f7108 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 3, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -37,6 +37,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index 82748751e..8a92b08c2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_document_ids: 1, deleted_documents: Some(1) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1"] }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Invalid type for filter subexpression: expected: String, Array, found: true.", error_code: "invalid_document_filter", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#invalid_document_filter" }, details: { original_filter: true, deleted_documents: Some(0) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: Bool(true) }} -4 {uid: 4, status: failed, error: ResponseError { code: 200, message: "Attribute `id` is not filterable. Available filterable attributes are: `catto`.\n1:3 id = 2", error_code: "invalid_document_filter", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#invalid_document_filter" }, details: { original_filter: "id = 2", deleted_documents: Some(0) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: String("id = 2") }} -5 {uid: 5, status: succeeded, details: { original_filter: "catto EXISTS", deleted_documents: Some(1) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: String("catto EXISTS") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_document_ids: 1, deleted_documents: Some(1) }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1"] }} +3 {uid: 3, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Invalid type for filter subexpression: expected: String, Array, found: true.", error_code: "invalid_document_filter", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#invalid_document_filter" }, details: { original_filter: true, deleted_documents: Some(0) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: Bool(true) }} +4 {uid: 4, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Attribute `id` is not filterable. Available filterable attributes are: `catto`.\n1:3 id = 2", error_code: "invalid_document_filter", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#invalid_document_filter" }, details: { original_filter: "id = 2", deleted_documents: Some(0) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: String("id = 2") }} +5 {uid: 5, batch_uid: 2, status: succeeded, details: { original_filter: "catto EXISTS", deleted_documents: Some(1) }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: String("catto EXISTS") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -51,6 +51,42 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] [timestamp] [2,3,4,5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +failed [2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"documentDeletion" [2,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap index 502ff0806..80d76435e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: Set({"catto"}), sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: NotSet, search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 3, indexed_documents: Some(3) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 3, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_document_ids: 1, deleted_documents: None }, kind: DocumentDeletion { index_uid: "doggos", documents_ids: ["1"] }} 3 {uid: 3, status: enqueued, details: { original_filter: true, deleted_documents: None }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: Bool(true) }} 4 {uid: 4, status: enqueued, details: { original_filter: "id = 2", deleted_documents: None }, kind: DocumentDeletionByFilter { index_uid: "doggos", filter_expr: String("id = 2") }} @@ -48,6 +48,35 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap index f7e5c35d3..056350b03 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,6 +33,23 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap index f252cc8ef..04abc4309 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 578b94061..1c4ccd6fe 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -33,7 +33,30 @@ catto [0,] ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap index 9c31fd318..918ce228b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -31,8 +31,24 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap index 9c31fd318..918ce228b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -31,8 +31,24 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap index c1869a475..189e84249 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap index c1869a475..189e84249 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,8 +30,24 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap index b4a6da3af..6a445dd2f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap index 41cfcfdab..f958f60ed 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -43,6 +43,39 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,2,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap index e6d0d8232..340eed008 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -41,6 +41,35 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap index bd4cf0c09..e7c904490 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -39,6 +39,35 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap index 746c7c870..76e87dca5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -37,6 +37,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap index 15cfd732a..99f4d2aac 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,6 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap index 9b5c6ce4c..15f21e689 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"A_fakerest": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(384), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet }), "B_small_hf": Set(EmbeddingSettings { source: Set(HuggingFace), model: Set("sentence-transformers/all-MiniLM-L6-v2"), revision: Set("e4ce9877abf3edfe10b0d82785e83bdcb973e22e"), api_key: NotSet, dimensions: NotSet, binary_quantized: NotSet, document_template: Set("{{doc.doggo}} the {{doc.breed}} best doggo"), document_template_max_bytes: NotSet, url: NotSet, request: NotSet, response: NotSet, headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,6 +34,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap index 3f34ca57b..8d1a6088a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ index_a [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap index f17bfe38f..02c70b5b9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ index_a [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap index 75d5d8760..073661a22 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -33,7 +33,23 @@ index_b [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap index a69818dfa..f2b1304b7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [0,] ---------------------------------------------------------------------- ### All Tasks: @@ -36,7 +36,23 @@ index_b [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index 9100e5075..590c2195a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "An unexpected crash occurred when processing the task.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "An unexpected crash occurred when processing the task.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -33,7 +33,30 @@ catto [0,] ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap index f252cc8ef..04abc4309 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ catto [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap index a34531f2a..e45973d8a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} 2 {uid: 2, status: enqueued, details: { deleted_documents: None }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- @@ -40,7 +40,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap index f163ee3d7..dcf93ae65 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} 2 {uid: 2, status: enqueued, details: { deleted_documents: None }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: @@ -43,7 +43,35 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +cattos [1,] +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap index 7e8db762f..addd5fa0b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} -2 {uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "cattos", primary_key: None }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: IndexDeletion { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -44,7 +44,40 @@ cattos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +"indexDeletion" [2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +cattos [1,] +doggos [0,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap index 1a29c1ac6..4d37e461d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap index 4020c2db0..a61a566ac 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,7 +33,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap index f25280bc1..4baac782e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -36,7 +36,23 @@ doggos [0,2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap index d67c659c6..b1f5bdf62 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} 2 {uid: 2, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} 3 {uid: 3, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} @@ -41,7 +41,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap index 3d5c28e2c..93bcdbc96 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} -2 {uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} -3 {uid: 3, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -47,7 +47,43 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"documentDeletion" [1,2,3,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap index c2ad519fa..40866fe27 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap index a9eb16d21..d16440245 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -37,7 +37,23 @@ doggos [0,1,2,3,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap index ad269dd7a..5fe720fca 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,7 +33,23 @@ doggos [0,1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap index 6267a840f..fbeeb76c3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -35,7 +35,23 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap index d45867c49..b0e395856 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} 2 {uid: 2, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} 3 {uid: 3, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} ---------------------------------------------------------------------- @@ -43,7 +43,35 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentDeletion" [1,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap index 9705c5321..4c6e0dbc8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} -2 {uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { deleted_documents: Some(0) }, kind: DocumentClear { index_uid: "doggos" }} 3 {uid: 3, status: enqueued, details: { deleted_documents: None }, kind: DocumentClear { index_uid: "doggos" }} ---------------------------------------------------------------------- ### Status: @@ -45,7 +45,39 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentDeletion" [1,2,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap index a07c46427..502324155 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("plankton") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("plankton") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("his_own_vomit") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("his_own_vomit") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("plankton") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("plankton") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("his_own_vomit") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("his_own_vomit") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -46,7 +46,40 @@ whalo: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [2,] +doggo [0,] +whalo [1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap index 8eb784c9b..7e04681ae 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggo [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap index 776d699e1..446635e88 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,7 +33,23 @@ whalo [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap index 1a3fc5b53..17d6e3c06 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -36,7 +36,23 @@ whalo [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index 6f59e49a2..1e27e37de 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} -2 {uid: 2, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("fish") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("fish") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("fish") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("fish") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -46,7 +46,41 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +failed [2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +doggo [1,] +whalo [2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap index 1fa3fa1ab..d08e1e91c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -36,7 +36,23 @@ whalo [2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap index 4baa9d87a..65002e258 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -39,7 +39,23 @@ whalo [3,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap index 62796a929..6e7351489 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -38,10 +38,26 @@ doggo [3,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap index 47a6dc6a7..e829d7511 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} 1 {uid: 1, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} 2 {uid: 2, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} 3 {uid: 3, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} @@ -43,7 +43,30 @@ a: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap index 13b783feb..57ed0b162 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} 2 {uid: 2, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} 3 {uid: 3, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} ---------------------------------------------------------------------- @@ -46,7 +46,35 @@ b: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap index 6b4bdb756..5bb7a5e4a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} 3 {uid: 3, status: enqueued, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} ---------------------------------------------------------------------- ### Status: @@ -49,7 +49,40 @@ c: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap index 038903c59..93a600529 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -52,7 +52,45 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +d [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap index c7ab30a36..a0713f706 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -4 {uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }} 5 {uid: 5, status: enqueued, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} ---------------------------------------------------------------------- ### Status: @@ -59,7 +59,50 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +"indexSwap" [4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,4,] +b [1,4,] +c [2,4,] +d [3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap index c0727d6e9..31d8e17ce 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} 4 {uid: 4, status: enqueued, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }} ---------------------------------------------------------------------- ### Status: @@ -55,7 +55,45 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +d [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap index 07acbe474..0faa77720 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -4 {uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }} -5 {uid: 5, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -61,7 +61,54 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] [timestamp] [5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +"indexSwap" [4,5,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,4,5,] +b [1,4,] +c [2,4,5,] +d [3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap index aeeba29f8..d9797e688 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap @@ -1,18 +1,18 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -4 {uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }} -5 {uid: 5, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} -6 {uid: 6, status: succeeded, details: { swaps: [] }, kind: IndexSwap { swaps: [] }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("c", "b") }, IndexSwap { indexes: ("a", "d") }] }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} +6 {uid: 6, batch_uid: 6, status: succeeded, details: { swaps: [] }, kind: IndexSwap { swaps: [] }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -65,7 +65,58 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [5,] [timestamp] [6,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,6,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +"indexSwap" [4,5,6,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,4,5,] +b [1,4,] +c [2,4,5,] +d [3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap index d1847fed1..f86b42f84 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} 4 {uid: 4, status: enqueued, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "d") }] }} 5 {uid: 5, status: enqueued, details: { swaps: [IndexSwap { indexes: ("a", "c") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "c") }] }} ---------------------------------------------------------------------- @@ -57,7 +57,45 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +d [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap index 038903c59..93a600529 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -52,7 +52,45 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +d [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index 4632820f0..a5f9c698a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} -4 {uid: 4, status: failed, error: ResponseError { code: 200, message: "Indexes `e`, `f` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "e") }, IndexSwap { indexes: ("d", "f") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "e") }, IndexSwap { indexes: ("d", "f") }] }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +4 {uid: 4, batch_uid: 4, status: failed, error: ResponseError { code: 200, message: "Indexes `e`, `f` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "e") }, IndexSwap { indexes: ("d", "f") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("a", "b") }, IndexSwap { indexes: ("c", "e") }, IndexSwap { indexes: ("d", "f") }] }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -60,7 +60,53 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +failed [4,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +"indexSwap" [4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,4,] +b [1,4,] +c [2,4,] +d [3,4,] +e [4,] +f [4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap index 038903c59..93a600529 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} -1 {uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} -2 {uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} -3 {uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "a", primary_key: Some("id") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "b", primary_key: Some("id") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "c", primary_key: Some("id") }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { primary_key: Some("id") }, kind: IndexCreation { index_uid: "d", primary_key: Some("id") }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -52,7 +52,45 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +a [0,] +b [1,] +c [2,] +d [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap index 4b4a50bfb..11676902e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,9 +33,25 @@ doggo [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap index 6e3a6e8ed..76397487f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -37,8 +37,31 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 83cfcdf07..7bd8fe151 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(1), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} -3 {uid: 3, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(0), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(1), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(0), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [1,] @@ -39,8 +39,37 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [2,3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"taskDeletion" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap index 302fd5f5e..804508a4b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { matched_tasks: 1, deleted_tasks: None, original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- @@ -40,8 +40,31 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap index 4b4a50bfb..11676902e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -33,9 +33,25 @@ doggo [1,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap index 6e3a6e8ed..76397487f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -37,8 +37,31 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index cf64406b8..6ed2345c0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(1), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { matched_tasks: 1, deleted_tasks: Some(1), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [1,] @@ -37,8 +37,36 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### Finished At: [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"taskDeletion" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap index 25e2deadc..678a16a18 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -36,9 +36,25 @@ doggo [2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap index 743cd615f..a56083a2c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: 0 {uid: 0, status: enqueued, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggo", primary_key: Some("bone"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { matched_tasks: 2, deleted_tasks: Some(0), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0, 1]> }} +3 {uid: 3, batch_uid: 0, status: succeeded, details: { matched_tasks: 2, deleted_tasks: Some(0), original_filter: "test_query" }, kind: TaskDeletion { query: "test_query", tasks: RoaringBitmap<[0, 1]> }} ---------------------------------------------------------------------- ### Status: enqueued [0,1,2,] @@ -42,9 +42,31 @@ doggo [2,] ### Finished At: [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"taskDeletion" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap index 5c4d9be04..a4b8c1684 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -39,9 +39,25 @@ doggo [2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap index 49df62cb7..40dae1197 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch Some(0): [3,] ---------------------------------------------------------------------- ### All Tasks: @@ -39,9 +39,25 @@ doggo [2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/after_the_second_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/after_the_second_task_deletion.snap index 59948c58c..03213fbb0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/after_the_second_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/after_the_second_task_deletion.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 5, + "batchUid": 4, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/everything_has_been_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/everything_has_been_processed.snap index 0f2f366e9..cc38f69a0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/everything_has_been_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/everything_has_been_processed.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 6, + "batchUid": 6, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_enqueued.snap index dc6b03517..3400d8950 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_enqueued.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 0, + "batchUid": 0, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 1, + "batchUid": 1, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -49,6 +51,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 2, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -69,6 +72,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -89,6 +93,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 4, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_processed.snap index 0200f7f4a..ab4210bed 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_deletion_have_been_processed.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 2, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -44,6 +46,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 4, + "batchUid": 2, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_queue_is_full.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_queue_is_full.snap index 988df76ec..8b69b1cc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_queue_is_full.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_auto_deletion_of_tasks/task_queue_is_full.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 0, + "batchUid": 0, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 1, + "batchUid": 1, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -49,6 +51,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 2, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -69,6 +72,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_deletion_have_not_been_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_deletion_have_not_been_enqueued.snap index 988df76ec..8b69b1cc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_deletion_have_not_been_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_deletion_have_not_been_enqueued.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 0, + "batchUid": 0, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 1, + "batchUid": 1, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -49,6 +51,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 2, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -69,6 +72,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_queue_is_full.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_queue_is_full.snap index 988df76ec..8b69b1cc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_queue_is_full.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_disable_auto_deletion_of_tasks/task_queue_is_full.snap @@ -1,9 +1,10 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- [ { "uid": 0, + "batchUid": 0, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -24,6 +25,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 1, + "batchUid": 1, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -49,6 +51,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 2, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", @@ -69,6 +72,7 @@ source: index-scheduler/src/lib.rs }, { "uid": 3, + "batchUid": null, "enqueuedAt": "[date]", "startedAt": "[date]", "finishedAt": "[date]", diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap index cb6ec63de..dfba0ed23 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap @@ -1,22 +1,22 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -10 {uid: 10, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +6 {uid: 6, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} +7 {uid: 7, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +8 {uid: 8, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} +9 {uid: 9, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +10 {uid: 10, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -57,7 +57,36 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,] [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap index 2e4845fb4..ae2297eeb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} @@ -55,6 +55,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -68,4 +92,3 @@ doggos: { number_of_documents: 0, field_distribution: {} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap index e046ed386..bdb6e01ff 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap index 1a29c1ac6..4d37e461d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap index e2e2133f5..61505d069 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} @@ -55,6 +55,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -68,4 +92,3 @@ doggos: { number_of_documents: 0, field_distribution: {} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap index 970587ba2..5739c8105 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap @@ -1,22 +1,22 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -10 {uid: 10, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +6 {uid: 6, batch_uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} +7 {uid: 7, batch_uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +8 {uid: 8, batch_uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} +9 {uid: 9, batch_uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +10 {uid: 10, batch_uid: 10, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -75,7 +75,71 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] [timestamp] [10,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +7 {uid: 7, } +8 {uid: 8, } +9 {uid: 9, } +10 {uid: 10, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,6,7,8,9,10,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,2,3,4,5,6,7,8,9,10,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,6,7,8,9,10,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +[timestamp] [10,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +[timestamp] [10,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +[timestamp] [10,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap index 5de505cf2..b806721fd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} 6 {uid: 6, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} 7 {uid: 7, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} 8 {uid: 8, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} @@ -65,6 +65,51 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] [timestamp] [5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,2,3,4,5,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000005 00000000-0000-0000-0000-000000000006 @@ -73,4 +118,3 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap index 606367737..e7740fcf1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap index c2ad519fa..40866fe27 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index 5a6ea9100..579b2246d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} -6 {uid: 6, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -7 {uid: 7, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} -8 {uid: 8, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -9 {uid: 9, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +1 {uid: 1, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} +6 {uid: 6, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +7 {uid: 7, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} +8 {uid: 8, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +9 {uid: 9, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -51,7 +51,31 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Finished At: [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap index e2217e1f4..29d40f34d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap index 02d0b1988..11c6d42de 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index 8164394c8..2dfa22ba1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} -6 {uid: 6, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -7 {uid: 7, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} -8 {uid: 8, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -9 {uid: 9, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 4, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 5, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} +6 {uid: 6, batch_uid: 6, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +7 {uid: 7, batch_uid: 7, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} +8 {uid: 8, batch_uid: 8, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +9 {uid: 9, batch_uid: 9, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: false }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -69,7 +69,66 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [8,] [timestamp] [9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +7 {uid: 7, } +8 {uid: 8, } +9 {uid: 9, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index 4e0bb97ab..5c4954e33 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 4, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: false }} 6 {uid: 6, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} 7 {uid: 7, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: false }} @@ -59,6 +59,46 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000005 00000000-0000-0000-0000-000000000006 @@ -67,4 +107,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap index f98802f21..686a1d431 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index ea6ef400a..4336145b7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +5 {uid: 5, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +7 {uid: 7, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +9 {uid: 9, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -55,7 +55,36 @@ doggos: { number_of_documents: 9, field_distribution: {"doggo": 9, "id": 9} } [timestamp] [0,] [timestamp] [1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [1,] +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index c27a1b5cb..a5154407d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Index `doggos` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} @@ -51,6 +51,30 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 @@ -63,4 +87,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap index 68599f03e..7e96a40c7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} @@ -55,6 +55,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -68,4 +92,3 @@ doggos: { number_of_documents: 0, field_distribution: {} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap index b442a9c2f..38c797bf6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap @@ -1,22 +1,22 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} -10 {uid: 10, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: false }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: false }} +4 {uid: 4, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: false }} +6 {uid: 6, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: false }} +8 {uid: 8, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: false }} +10 {uid: 10, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -57,7 +57,36 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,] [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [1,] +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap index e046ed386..bdb6e01ff 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: None }, kind: IndexCreation { index_uid: "doggos", primary_key: None }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,7 +34,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap index 1a29c1ac6..4d37e461d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap index fde8e3451..37a09f901 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -38,6 +38,23 @@ doggos [0,1,2,3,4,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -46,4 +63,3 @@ doggos [0,1,2,3,4,] 00000000-0000-0000-0000-000000000004 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index 85d7ba460..d786f8b22 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -49,7 +49,44 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "id": 2} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [1,3,] +failed [0,2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index ab788cc36..1e2b68bc3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} @@ -42,10 +42,34 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000002 00000000-0000-0000-0000-000000000003 00000000-0000-0000-0000-000000000004 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 2a8748657..3227bdf8f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -1,15 +1,15 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -47,8 +47,41 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [1,] +failed [0,2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000004 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index 58cdbe432..d0fc43f43 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":0,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"id\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- @@ -45,9 +45,38 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [1,] +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000003 00000000-0000-0000-0000-000000000004 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap index 5699c58c4..83309739d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -34,10 +34,26 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap index 85689fa4d..3029a930b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bloup"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- @@ -38,9 +38,32 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index 18db64ca4..ef1ec1880 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bloup"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -41,8 +41,36 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +failed [1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index 4a9edc602..d7b5c6f02 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bloup"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bloup"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -43,7 +43,39 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +failed [1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap index 1187159b7..cac51c8c0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -34,10 +34,26 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap index 22b91bb60..c90477046 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- @@ -38,9 +38,32 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 05eca0af1..3b16d875b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `id`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: @@ -41,8 +41,36 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +failed [1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap index 47b0994ec..a738c59cb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -40,6 +40,23 @@ doggos [0,1,2,3,4,5,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -49,4 +66,3 @@ doggos [0,1,2,3,4,5,] 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index a7464685a..dbe7f75a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -51,7 +51,44 @@ doggos: { number_of_documents: 4, field_distribution: {"doggo": 4, "paw": 4} } [timestamp] [2,] [timestamp] [3,4,5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [2,3,] +failed [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index 5c7f7e8d8..7ee25125b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} @@ -44,6 +44,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 @@ -52,4 +76,3 @@ doggos: { number_of_documents: 0, field_distribution: {} } 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index 2c255aeba..2cbfaa5cf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} @@ -46,6 +46,34 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +failed [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000002 00000000-0000-0000-0000-000000000003 @@ -53,4 +81,3 @@ doggos: { number_of_documents: 0, field_distribution: {} } 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index 2f944adcf..7a6dc3ead 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: failed, error: ResponseError { code: 200, message: "The primary key inference failed as the engine did not find any field ending with `id` in its name. Please specify the primary key manually using the `primaryKey` query parameter.", error_code: "index_primary_key_no_candidate_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_no_candidate_found" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Document doesn't have a `bork` attribute: `{\"paw\":1,\"doggo\":\"jean bob\"}`.", error_code: "missing_document_id", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#missing_document_id" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("paw"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} @@ -49,10 +49,42 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "paw": 1} } [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [2,] +failed [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000003 00000000-0000-0000-0000-000000000004 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap index c89abf033..df0b40cab 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -40,6 +40,23 @@ doggos [0,1,2,3,4,5,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -49,4 +66,3 @@ doggos [0,1,2,3,4,5,] 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index 1f55e8f6d..0a4e65ea9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -1,17 +1,17 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -51,7 +51,44 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "doggoid": 5} [timestamp] [2,] [timestamp] [3,4,5,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,2,3,] +failed [1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap index 532cef143..20d5216a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} 1 {uid: 1, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} @@ -44,6 +44,30 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000001 00000000-0000-0000-0000-000000000002 @@ -52,4 +76,3 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index 2920c3b2e..a044ca823 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -1,13 +1,13 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} 2 {uid: 2, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} @@ -47,6 +47,35 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} [timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +failed [1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000002 00000000-0000-0000-0000-000000000003 @@ -54,4 +83,3 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index 8981dd8c3..238636df6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -1,14 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: failed, error: ResponseError { code: 200, message: "Index already has a primary key: `doggoid`.", error_code: "index_primary_key_already_exists", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_primary_key_already_exists" }, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("bork"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} 3 {uid: 3, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} 4 {uid: 4, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("doggoid"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} @@ -49,10 +49,42 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "doggoid": 2} [timestamp] [1,] [timestamp] [2,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,2,] +failed [1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000003 00000000-0000-0000-0000-000000000004 00000000-0000-0000-0000-000000000005 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap index 21581fe78..e91fda83f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap index fabf764bc..9e8ce7422 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -52,7 +52,31 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } ### Finished At: [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap index 1beba7264..6289818cc 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap index a0b121320..b9d1a914b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -70,7 +70,66 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [8,] [timestamp] [9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +7 {uid: 7, } +8 {uid: 8, } +9 {uid: 9, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap index 88bf59f8e..ea13f7d97 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} 6 {uid: 6, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} 7 {uid: 7, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} @@ -60,6 +60,46 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000005 00000000-0000-0000-0000-000000000006 @@ -68,4 +108,3 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap index 53f0fbc9b..5a03a2aa8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap index d8383818e..0239ded3a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -52,7 +52,31 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } ### Finished At: [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap index 6785786e3..2bd63c492 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap index 4c8fd7ea6..9222896d5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -70,7 +70,66 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [8,] [timestamp] [9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +7 {uid: 7, } +8 {uid: 8, } +9 {uid: 9, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap index f184bb3cb..3f599636b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = false -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} 6 {uid: 6, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} 7 {uid: 7, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} @@ -60,6 +60,46 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000005 00000000-0000-0000-0000-000000000006 @@ -68,4 +108,3 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap index 9095f031b..47e701bc9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -48,6 +48,23 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000000 00000000-0000-0000-0000-000000000001 @@ -61,4 +78,3 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap index 6c6fba517..f9eb836ef 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap @@ -1,21 +1,21 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} -5 {uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} -6 {uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} -7 {uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} -8 {uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} -9 {uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +5 {uid: 5, batch_uid: 5, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} +6 {uid: 6, batch_uid: 6, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} +7 {uid: 7, batch_uid: 7, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} +8 {uid: 8, batch_uid: 8, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000008, documents_count: 1, allow_index_creation: true }} +9 {uid: 9, batch_uid: 9, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000009, documents_count: 1, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -70,7 +70,66 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [8,] [timestamp] [9,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +5 {uid: 5, } +6 {uid: 6, } +7 {uid: 7, } +8 {uid: 8, } +9 {uid: 9, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +[timestamp] [5,] +[timestamp] [6,] +[timestamp] [7,] +[timestamp] [8,] +[timestamp] [9,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap index 8aa7cfbea..323cb7552 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap @@ -1,16 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} -4 {uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 3, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000003, documents_count: 1, allow_index_creation: true }} +4 {uid: 4, batch_uid: 4, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000004, documents_count: 1, allow_index_creation: true }} 5 {uid: 5, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000005, documents_count: 1, allow_index_creation: true }} 6 {uid: 6, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: UpdateDocuments, content_file: 00000000-0000-0000-0000-000000000006, documents_count: 1, allow_index_creation: true }} 7 {uid: 7, status: enqueued, details: { received_documents: 1, indexed_documents: None }, kind: DocumentAdditionOrUpdate { index_uid: "doggos", primary_key: Some("id"), method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000007, documents_count: 1, allow_index_creation: true }} @@ -60,6 +60,46 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [3,] [timestamp] [4,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +4 {uid: 4, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,1,2,3,4,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +[timestamp] [4,] +---------------------------------------------------------------------- ### File Store: 00000000-0000-0000-0000-000000000005 00000000-0000-0000-0000-000000000006 @@ -68,4 +108,3 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 00000000-0000-0000-0000-000000000009 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap index 37f0a062d..ac6e7b258 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,6 +30,23 @@ doggos [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap index 3906fc6fc..f2108b7b0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap @@ -1,12 +1,12 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"default": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(4), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"default": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(4), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"default": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(4), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData } }, kind: SettingsUpdate { index_uid: "doggos", new_settings: Settings { displayed_attributes: WildcardSetting(NotSet), searchable_attributes: WildcardSetting(NotSet), filterable_attributes: NotSet, sortable_attributes: NotSet, ranking_rules: NotSet, stop_words: NotSet, non_separator_tokens: NotSet, separator_tokens: NotSet, dictionary: NotSet, synonyms: NotSet, distinct_attribute: NotSet, proximity_precision: NotSet, typo_tolerance: NotSet, faceting: NotSet, pagination: NotSet, embedders: Set({"default": Set(EmbeddingSettings { source: Set(Rest), model: NotSet, revision: NotSet, api_key: Set("My super secret"), dimensions: Set(4), binary_quantized: NotSet, document_template: NotSet, document_template_max_bytes: NotSet, url: Set("http://localhost:7777"), request: Set(String("{{text}}")), response: Set(String("{{embedding}}")), headers: NotSet, distribution: NotSet })}), search_cutoff_ms: NotSet, localized_attributes: NotSet, _kind: PhantomData }, is_deletion: false, allow_index_creation: true }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,6 +34,30 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### Finished At: [timestamp] [0,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"settingsUpdate" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +doggos [0,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap index f17bfe38f..02c70b5b9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap @@ -1,8 +1,8 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: @@ -30,7 +30,23 @@ index_a [0,] ---------------------------------------------------------------------- ### Finished At: ---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 534d3b5d4..d8f4f0521 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -3,7 +3,7 @@ use std::collections::{BTreeSet, HashSet}; use std::ops::Bound; -use meilisearch_types::batches::BatchId; +use meilisearch_types::batches::{Batch, BatchId}; use meilisearch_types::heed::types::DecodeIgnore; use meilisearch_types::heed::{Database, RoTxn, RwTxn}; use meilisearch_types::milli::CboRoaringBitmapCodec; @@ -11,13 +11,64 @@ use meilisearch_types::tasks::{Details, IndexSwap, Kind, KindWithContent, Status use roaring::{MultiOps, RoaringBitmap}; use time::OffsetDateTime; -use crate::{Error, IndexScheduler, Result, Task, TaskId, BEI128}; +use crate::{Error, IndexScheduler, ProcessingTasks, Result, Task, TaskId, BEI128}; + +/// This structure contains all the information required to write a batch in the database without reading the tasks. +/// It'll stay in RAM so it must be small. +pub(crate) struct CachedBatch { + uid: BatchId, + statuses: HashSet, + kinds: HashSet, + indexes: HashSet, + canceled_by: HashSet, + oldest_enqueued_at: Option, + earliest_enqueued_at: Option, + started_at: OffsetDateTime, + finished_at: OffsetDateTime, +} + +impl CachedBatch { + pub fn new(uid: BatchId, started_at: OffsetDateTime, finished_at: OffsetDateTime) -> Self { + Self { + uid, + statuses: HashSet::default(), + kinds: HashSet::default(), + indexes: HashSet::default(), + canceled_by: HashSet::default(), + oldest_enqueued_at: None, + earliest_enqueued_at: None, + started_at, + finished_at, + } + } + + pub fn update(&mut self, task: &Task) { + self.statuses.insert(task.status); + self.kinds.insert(task.kind.as_kind()); + self.indexes.extend(task.indexes().iter().map(|s| s.to_string())); + if let Some(canceled_by) = task.canceled_by { + self.canceled_by.insert(canceled_by); + } + self.oldest_enqueued_at = + Some(self.oldest_enqueued_at.map_or(task.enqueued_at, |oldest_enqueued_at| { + task.enqueued_at.min(oldest_enqueued_at) + })); + self.earliest_enqueued_at = + Some(self.earliest_enqueued_at.map_or(task.enqueued_at, |earliest_enqueued_at| { + task.enqueued_at.max(earliest_enqueued_at) + })); + } +} impl IndexScheduler { pub(crate) fn all_task_ids(&self, rtxn: &RoTxn) -> Result { enum_iterator::all().map(|s| self.get_status(rtxn, s)).union() } + pub(crate) fn all_batch_ids(&self, rtxn: &RoTxn) -> Result { + enum_iterator::all().map(|s| self.get_batch_status(rtxn, s)).union() + } + pub(crate) fn last_task_id(&self, rtxn: &RoTxn) -> Result> { Ok(self.all_tasks.remap_data_type::().last(rtxn)?.map(|(k, _)| k + 1)) } @@ -39,6 +90,50 @@ impl IndexScheduler { Ok(self.all_tasks.get(rtxn, &task_id)?) } + pub(crate) fn get_batch(&self, rtxn: &RoTxn, batch_id: BatchId) -> Result> { + Ok(self.all_batches.get(rtxn, &batch_id)?) + } + + pub(crate) fn write_batch(&self, wtxn: &mut RwTxn, batch: CachedBatch) -> Result<()> { + self.all_batches.put( + wtxn, + &batch.uid, + &Batch { + uid: batch.uid, + started_at: batch.started_at, + finished_at: Some(batch.finished_at), + }, + )?; + + for status in batch.statuses { + self.update_batch_status(wtxn, status, |bitmap| { + bitmap.insert(batch.uid); + })?; + } + + for kind in batch.kinds { + self.update_batch_kind(wtxn, kind, |bitmap| { + bitmap.insert(batch.uid); + })?; + } + + for index in batch.indexes { + self.update_batch_index(wtxn, &index, |bitmap| { + bitmap.insert(batch.uid); + })?; + } + if let Some(enqueued_at) = batch.oldest_enqueued_at { + insert_task_datetime(wtxn, self.batch_enqueued_at, enqueued_at, batch.uid)?; + } + if let Some(enqueued_at) = batch.earliest_enqueued_at { + insert_task_datetime(wtxn, self.batch_enqueued_at, enqueued_at, batch.uid)?; + } + insert_task_datetime(wtxn, self.batch_started_at, batch.started_at, batch.uid)?; + insert_task_datetime(wtxn, self.batch_finished_at, batch.finished_at, batch.uid)?; + + Ok(()) + } + /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a /// `CorruptedTaskQueue` error will be throwed. pub(crate) fn get_existing_tasks_with_batch_id( @@ -72,11 +167,29 @@ impl IndexScheduler { .collect::>() } + /// Convert an iterator to a `Vec` of batches. The batches MUST exist or a + /// `CorruptedTaskQueue` error will be throwed. + pub(crate) fn get_existing_batches( + &self, + rtxn: &RoTxn, + tasks: impl IntoIterator, + ) -> Result> { + tasks + .into_iter() + .map(|batch_id| { + self.get_batch(rtxn, batch_id) + .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)) + }) + .collect::>() + } + pub(crate) fn update_task(&self, wtxn: &mut RwTxn, task: &Task) -> Result<()> { let old_task = self.get_task(wtxn, task.uid)?.ok_or(Error::CorruptedTaskQueue)?; debug_assert_eq!(old_task.uid, task.uid); + debug_assert!(old_task.batch_uid.is_none() && task.batch_uid.is_some()); + // TODO: This shouldn't ever happen, we should assert it if old_task == *task { return Ok(()); } @@ -142,6 +255,28 @@ impl IndexScheduler { Ok(()) } + /// Returns the whole set of batches that belongs to this index. + pub(crate) fn index_batches(&self, rtxn: &RoTxn, index: &str) -> Result { + Ok(self.batch_index_tasks.get(rtxn, index)?.unwrap_or_default()) + } + + pub(crate) fn update_batch_index( + &self, + wtxn: &mut RwTxn, + index: &str, + f: impl Fn(&mut RoaringBitmap), + ) -> Result<()> { + let mut batches = self.index_batches(wtxn, index)?; + f(&mut batches); + if batches.is_empty() { + self.batch_index_tasks.delete(wtxn, index)?; + } else { + self.batch_index_tasks.put(wtxn, index, &batches)?; + } + + Ok(()) + } + pub(crate) fn get_status(&self, rtxn: &RoTxn, status: Status) -> Result { Ok(self.status.get(rtxn, &status)?.unwrap_or_default()) } @@ -168,6 +303,32 @@ impl IndexScheduler { Ok(()) } + pub(crate) fn get_batch_status(&self, rtxn: &RoTxn, status: Status) -> Result { + Ok(self.batch_status.get(rtxn, &status)?.unwrap_or_default()) + } + + pub(crate) fn put_batch_status( + &self, + wtxn: &mut RwTxn, + status: Status, + bitmap: &RoaringBitmap, + ) -> Result<()> { + Ok(self.batch_status.put(wtxn, &status, bitmap)?) + } + + pub(crate) fn update_batch_status( + &self, + wtxn: &mut RwTxn, + status: Status, + f: impl Fn(&mut RoaringBitmap), + ) -> Result<()> { + let mut tasks = self.get_batch_status(wtxn, status)?; + f(&mut tasks); + self.put_batch_status(wtxn, status, &tasks)?; + + Ok(()) + } + pub(crate) fn get_kind(&self, rtxn: &RoTxn, kind: Kind) -> Result { Ok(self.kind.get(rtxn, &kind)?.unwrap_or_default()) } @@ -193,6 +354,32 @@ impl IndexScheduler { Ok(()) } + + pub(crate) fn get_batch_kind(&self, rtxn: &RoTxn, kind: Kind) -> Result { + Ok(self.batch_kind.get(rtxn, &kind)?.unwrap_or_default()) + } + + pub(crate) fn put_batch_kind( + &self, + wtxn: &mut RwTxn, + kind: Kind, + bitmap: &RoaringBitmap, + ) -> Result<()> { + Ok(self.batch_kind.put(wtxn, &kind, bitmap)?) + } + + pub(crate) fn update_batch_kind( + &self, + wtxn: &mut RwTxn, + kind: Kind, + f: impl Fn(&mut RoaringBitmap), + ) -> Result<()> { + let mut tasks = self.get_batch_kind(wtxn, kind)?; + f(&mut tasks); + self.put_batch_kind(wtxn, kind, &tasks)?; + + Ok(()) + } } pub(crate) fn insert_task_datetime( @@ -227,6 +414,7 @@ pub(crate) fn remove_task_datetime( Ok(()) } +// TODO: Rename the function since it also applies to batches pub(crate) fn keep_tasks_within_datetimes( rtxn: &RoTxn, tasks: &mut RoaringBitmap, diff --git a/crates/meilisearch-types/src/batch_view.rs b/crates/meilisearch-types/src/batch_view.rs new file mode 100644 index 000000000..15e1f8ab9 --- /dev/null +++ b/crates/meilisearch-types/src/batch_view.rs @@ -0,0 +1,30 @@ +use serde::Serialize; +use time::{Duration, OffsetDateTime}; + +use crate::{ + batches::{Batch, BatchId}, + tasks::serialize_duration, +}; + +#[derive(Debug, Clone, PartialEq, Eq, Serialize)] +#[serde(rename_all = "camelCase")] +pub struct BatchView { + pub uid: BatchId, + #[serde(serialize_with = "serialize_duration", default)] + pub duration: Option, + #[serde(with = "time::serde::rfc3339", default)] + pub started_at: OffsetDateTime, + #[serde(with = "time::serde::rfc3339::option", default)] + pub finished_at: Option, +} + +impl BatchView { + pub fn from_batch(batch: &Batch) -> Self { + Self { + uid: batch.uid, + duration: batch.finished_at.map(|finished_at| finished_at - batch.started_at), + started_at: batch.started_at, + finished_at: batch.finished_at, + } + } +} diff --git a/crates/meilisearch-types/src/error.rs b/crates/meilisearch-types/src/error.rs index c2c40be5f..00f88b7b4 100644 --- a/crates/meilisearch-types/src/error.rs +++ b/crates/meilisearch-types/src/error.rs @@ -344,6 +344,7 @@ NoSpaceLeftOnDevice , System , UNPROCESSABLE_ENT PayloadTooLarge , InvalidRequest , PAYLOAD_TOO_LARGE ; TooManySearchRequests , System , SERVICE_UNAVAILABLE ; TaskNotFound , InvalidRequest , NOT_FOUND ; +BatchNotFound , InvalidRequest , NOT_FOUND ; TooManyOpenFiles , System , UNPROCESSABLE_ENTITY ; TooManyVectors , InvalidRequest , BAD_REQUEST ; UnretrievableDocument , Internal , BAD_REQUEST ; diff --git a/crates/meilisearch-types/src/lib.rs b/crates/meilisearch-types/src/lib.rs index e10b2950b..a1a57b7e6 100644 --- a/crates/meilisearch-types/src/lib.rs +++ b/crates/meilisearch-types/src/lib.rs @@ -1,3 +1,4 @@ +pub mod batch_view; pub mod batches; pub mod compression; pub mod deserr; diff --git a/crates/meilisearch/src/routes/batches.rs b/crates/meilisearch/src/routes/batches.rs index f8e626a17..9e432bcc1 100644 --- a/crates/meilisearch/src/routes/batches.rs +++ b/crates/meilisearch/src/routes/batches.rs @@ -2,25 +2,24 @@ use actix_web::{ web::{self, Data}, HttpResponse, }; +use deserr::actix_web::AwebQueryParameter; use index_scheduler::{IndexScheduler, Query}; use meilisearch_types::{ - batches::BatchId, error::ResponseError, keys::actions, task_view::TaskView, + batch_view::BatchView, batches::BatchId, deserr::DeserrQueryParamError, error::ResponseError, + keys::actions, }; +use serde::Serialize; use crate::extractors::{authentication::GuardedData, sequential_extractor::SeqHandler}; -use super::ActionPolicy; +use super::{tasks::TasksFilterQuery, ActionPolicy}; pub fn configure(cfg: &mut web::ServiceConfig) { - cfg - // .service( - // web::resource("") - // .route(web::get().to(SeqHandler(get_tasks))) - // ) + cfg.service(web::resource("").route(web::get().to(SeqHandler(get_batches)))) .service(web::resource("/{batch_id}").route(web::get().to(SeqHandler(get_batch)))); } -async fn get_task( +async fn get_batch( index_scheduler: GuardedData, Data>, batch_uid: web::Path, ) -> Result { @@ -37,12 +36,45 @@ async fn get_task( let query = index_scheduler::Query { uids: Some(vec![batch_uid]), ..Query::default() }; let filters = index_scheduler.filters(); - let (tasks, _) = index_scheduler.get_tasks_from_authorized_indexes(query, filters)?; + let (batches, _) = index_scheduler.get_batches_from_authorized_indexes(query, filters)?; - if let Some(task) = tasks.first() { - let task_view = TaskView::from_task(task); + if let Some(batch) = batches.first() { + let task_view = BatchView::from_batch(batch); Ok(HttpResponse::Ok().json(task_view)) } else { Err(index_scheduler::Error::TaskNotFound(batch_uid).into()) } } + +#[derive(Debug, Serialize)] +pub struct AllBatches { + results: Vec, + total: u64, + limit: u32, + from: Option, + next: Option, +} + +async fn get_batches( + index_scheduler: GuardedData, Data>, + params: AwebQueryParameter, +) -> Result { + let mut params = params.into_inner(); + // We +1 just to know if there is more after this "page" or not. + params.limit.0 = params.limit.0.saturating_add(1); + let limit = params.limit.0; + let query = params.into_query(); + + let filters = index_scheduler.filters(); + let (tasks, total) = index_scheduler.get_batches_from_authorized_indexes(query, filters)?; + let mut results: Vec<_> = tasks.iter().map(BatchView::from_batch).collect(); + + // If we were able to fetch the number +1 tasks we asked + // it means that there is more to come. + let next = if results.len() == limit as usize { results.pop().map(|t| t.uid) } else { None }; + + let from = results.first().map(|t| t.uid); + let tasks = AllBatches { results, limit: limit.saturating_sub(1), total, from, next }; + + Ok(HttpResponse::Ok().json(tasks)) +} diff --git a/crates/meilisearch/src/routes/mod.rs b/crates/meilisearch/src/routes/mod.rs index f5c512ab9..91237b707 100644 --- a/crates/meilisearch/src/routes/mod.rs +++ b/crates/meilisearch/src/routes/mod.rs @@ -33,6 +33,7 @@ pub mod tasks; pub fn configure(cfg: &mut web::ServiceConfig) { cfg.service(web::scope("/tasks").configure(tasks::configure)) + .service(web::scope("/batches").configure(batches::configure)) .service(web::resource("/health").route(web::get().to(get_health))) .service(web::scope("/logs").configure(logs::configure)) .service(web::scope("/keys").configure(api_key::configure)) diff --git a/crates/meilisearch/src/routes/tasks.rs b/crates/meilisearch/src/routes/tasks.rs index 556b71bc5..7cdad308e 100644 --- a/crates/meilisearch/src/routes/tasks.rs +++ b/crates/meilisearch/src/routes/tasks.rs @@ -70,7 +70,7 @@ pub struct TasksFilterQuery { } impl TasksFilterQuery { - fn into_query(self) -> Query { + pub(crate) fn into_query(self) -> Query { Query { limit: Some(self.limit.0), from: self.from.as_deref().copied(), From d489f5635f8737460e7167964c76b0ff487523b1 Mon Sep 17 00:00:00 2001 From: Tamo Date: Mon, 18 Nov 2024 10:46:56 +0100 Subject: [PATCH 03/22] add the mapping between the task and batches --- crates/index-scheduler/src/insta_snapshot.rs | 18 +++ crates/index-scheduler/src/lib.rs | 145 +++++++++++------- .../initial_tasks_enqueued.snap | 2 + .../aborted_indexation.snap | 3 + .../first_task_processed.snap | 3 + ...rocessing_second_task_cancel_enqueued.snap | 3 + .../after_dump_register.snap | 2 + .../cancel_registered.snap | 2 + .../aborted_indexation.snap | 2 + .../cancel_task_registered.snap | 2 + .../initial_task_processing.snap | 2 + .../registered_the_first_task.snap | 2 + .../cancel_processed.snap | 4 + .../initial_task_processed.snap | 3 + .../registered_the_first_task.snap | 2 + .../all_tasks_processed.snap | 8 + .../document_addition/after_register.snap | 2 + .../after_the_batch_creation.snap | 2 + .../once_everything_is_processed.snap | 3 + .../after_processing_the_batch.snap | 3 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../before_index_creation.snap | 3 + .../both_task_succeeded.snap | 4 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../registered_the_third_task.snap | 2 + .../1.snap | 2 + .../2.snap | 3 + .../after_failing_the_deletion.snap | 3 + .../after_last_successful_addition.snap | 4 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../document_addition_batch_created.snap | 2 + .../document_addition_failed.snap | 3 + .../registered_the_first_task.snap | 2 + .../after_adding_the_documents.snap | 4 + .../after_adding_the_settings.snap | 3 + .../after_removing_the_documents.snap | 5 + .../registered_the_document_deletions.snap | 4 + ...red_the_setting_and_document_addition.snap | 2 + .../after_register.snap | 2 + .../index_creation_failed.snap | 3 + .../after_batch_succeeded.snap | 2 + .../after_failing_to_commit.snap | 2 + ...eeded_but_index_scheduler_not_updated.snap | 2 + .../registered_the_first_task.snap | 2 + .../task_successfully_processed.snap | 3 + .../Intel to kefir succeeds.snap | 5 + .../lib.rs/import_vectors/Intel to kefir.snap | 4 + .../import_vectors/adding Intel succeeds.snap | 4 + .../import_vectors/after adding Intel.snap | 3 + ...ter_registering_settings_task_vectors.snap | 2 + .../settings_update_processed_vectors.snap | 3 + .../after_batch_creation.snap | 2 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../registered_the_third_task.snap | 2 + .../index_creation_failed.snap | 3 + .../registered_the_first_task.snap | 2 + .../processed_the_first_task.snap | 3 + .../processed_the_second_task.snap | 4 + .../processed_the_third_task.snap | 5 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../registered_the_third_task.snap | 2 + .../first.snap | 3 + .../fourth.snap | 6 + .../registered_the_first_task.snap | 2 + .../registered_the_fourth_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../registered_the_third_task.snap | 2 + .../second.snap | 4 + .../third.snap | 5 + .../processed_all_tasks.snap | 5 + .../registered_the_first_task.snap | 2 + .../registered_the_second_task.snap | 2 + .../registered_the_third_task.snap | 2 + .../lib.rs/query_tasks_simple/end.snap | 5 + .../lib.rs/query_tasks_simple/start.snap | 2 + .../query_tasks_special_rules/start.snap | 2 + ...everything_is_successfully_registered.snap | 2 + .../lib.rs/swap_indexes/create_a.snap | 3 + .../lib.rs/swap_indexes/create_b.snap | 4 + .../lib.rs/swap_indexes/create_c.snap | 5 + .../lib.rs/swap_indexes/create_d.snap | 6 + .../swap_indexes/first_swap_processed.snap | 7 + .../swap_indexes/first_swap_registered.snap | 6 + .../swap_indexes/second_swap_processed.snap | 8 + .../third_empty_swap_processed.snap | 9 ++ .../swap_indexes/two_swaps_registered.snap | 6 + .../after_the_index_creation.snap | 6 + .../first_swap_failed.snap | 7 + .../initial_tasks_processed.snap | 6 + .../initial_tasks_enqueued.snap | 2 + .../initial_tasks_processed.snap | 3 + .../task_deletion_processed.snap | 4 + .../after_registering_the_task_deletion.snap | 3 + .../initial_tasks_enqueued.snap | 2 + .../initial_tasks_processed.snap | 3 + .../task_deletion_processed.snap | 4 + .../initial_tasks_enqueued.snap | 2 + .../task_deletion_done.snap | 3 + .../task_deletion_enqueued.snap | 2 + .../task_deletion_processing.snap | 2 + .../after_processing_the_10_tasks.snap | 4 + .../after_registering_the_10_tasks.snap | 3 + .../processed_the_first_task.snap | 3 + .../registered_the_first_task.snap | 2 + .../after_registering_the_10_tasks.snap | 3 + .../all_tasks_processed.snap | 13 ++ .../five_tasks_processed.snap | 8 + .../processed_the_first_task.snap | 3 + .../registered_the_first_task.snap | 2 + .../after_processing_the_10_tasks.snap | 3 + .../after_registering_the_10_tasks.snap | 2 + .../after_registering_the_10_tasks.snap | 2 + .../all_tasks_processed.snap | 12 ++ .../five_tasks_processed.snap | 7 + .../after_registering_the_10_tasks.snap | 2 + .../all_tasks_processed.snap | 4 + .../only_first_task_failed.snap | 3 + .../after_registering_the_10_tasks.snap | 3 + .../all_tasks_processed.snap | 4 + .../processed_the_first_task.snap | 3 + .../registered_the_first_task.snap | 2 + .../after_registering_the_5_tasks.snap | 2 + .../fifth_task_succeeds.snap | 6 + .../first_and_second_task_fails.snap | 3 + .../fourth_task_fails.snap | 5 + .../third_task_succeeds.snap | 4 + .../after_registering_the_3_tasks.snap | 2 + .../only_first_task_succeed.snap | 3 + .../second_task_fails.snap | 4 + .../third_task_fails.snap | 5 + .../after_registering_the_3_tasks.snap | 2 + .../only_first_task_succeed.snap | 3 + .../second_and_third_tasks_fails.snap | 4 + .../after_registering_the_6_tasks.snap | 2 + .../all_other_tasks_succeeds.snap | 6 + .../first_task_fails.snap | 3 + .../second_task_fails.snap | 4 + .../third_task_succeeds.snap | 5 + .../after_registering_the_6_tasks.snap | 2 + .../all_other_tasks_succeeds.snap | 6 + .../first_task_succeed.snap | 3 + .../second_task_fails.snap | 4 + .../third_task_succeeds.snap | 5 + .../lib.rs/test_document_replace/1.snap | 2 + .../lib.rs/test_document_replace/2.snap | 3 + .../after_registering_the_10_tasks.snap | 2 + .../all_tasks_processed.snap | 12 ++ .../five_tasks_processed.snap | 7 + .../lib.rs/test_document_update/1.snap | 2 + .../lib.rs/test_document_update/2.snap | 3 + .../after_registering_the_10_tasks.snap | 2 + .../all_tasks_processed.snap | 12 ++ .../five_tasks_processed.snap | 7 + .../after_registering_the_10_tasks.snap | 2 + .../all_tasks_processed.snap | 12 ++ .../five_tasks_processed.snap | 7 + .../after_registering_settings_task.snap | 2 + .../settings_update_processed.snap | 3 + .../registered_a_task.snap | 2 + crates/index-scheduler/src/utils.rs | 22 ++- crates/meilisearch/src/routes/tasks.rs | 27 ++-- crates/meilisearch/tests/tasks/errors.rs | 8 +- 167 files changed, 730 insertions(+), 68 deletions(-) diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index 4cf639889..2ca12e1ee 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -26,6 +26,7 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { env, all_tasks, all_batches, + batch_to_tasks_mapping, // task reverse index status, kind, @@ -111,6 +112,10 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { snap.push_str(&snapshot_all_batches(&rtxn, *all_batches)); snap.push_str("----------------------------------------------------------------------\n"); + snap.push_str("### Batch to tasks mapping:\n"); + snap.push_str(&snapshot_batches_to_tasks_mappings(&rtxn, *batch_to_tasks_mapping)); + snap.push_str("----------------------------------------------------------------------\n"); + snap.push_str("### Batches Status:\n"); snap.push_str(&snapshot_status(&rtxn, *batch_status)); snap.push_str("----------------------------------------------------------------------\n"); @@ -186,6 +191,19 @@ pub fn snapshot_all_batches(rtxn: &RoTxn, db: Database>) snap } +pub fn snapshot_batches_to_tasks_mappings( + rtxn: &RoTxn, + db: Database, +) -> String { + let mut snap = String::new(); + let iter = db.iter(rtxn).unwrap(); + for next in iter { + let (batch_id, tasks) = next.unwrap(); + snap.push_str(&format!("{batch_id} {}\n", snapshot_bitmap(&tasks))); + } + snap +} + pub fn snapshot_date_db(rtxn: &RoTxn, db: Database) -> String { let mut snap = String::new(); let iter = db.iter(rtxn).unwrap(); diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 78bf1268b..4d242d677 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -87,6 +87,10 @@ pub struct Query { pub from: Option, /// The order used to return the tasks. By default the newest tasks are returned first and the boolean is `false`. pub reverse: Option, + /// The [task ids](`meilisearch_types::tasks::Task::uid`) to be matched + pub uids: Option>, + /// The [batch ids](`meilisearch_types::batches::Batch::uid`) to be matched + pub batch_uids: Option>, /// The allowed [statuses](`meilisearch_types::tasks::Task::status`) of the matched tasls pub statuses: Option>, /// The allowed [kinds](meilisearch_types::tasks::Kind) of the matched tasks. @@ -101,8 +105,6 @@ pub struct Query { pub types: Option>, /// The allowed [index ids](meilisearch_types::tasks::Task::index_uid) of the matched tasks pub index_uids: Option>, - /// The [task ids](`meilisearch_types::tasks::Task::uid`) to be matched - pub uids: Option>, /// The [task ids](`meilisearch_types::tasks::Task::uid`) of the [`TaskCancelation`](meilisearch_types::tasks::Task::Kind::TaskCancelation) tasks /// that canceled the matched tasks. pub canceled_by: Option>, @@ -130,10 +132,11 @@ impl Query { limit: None, from: None, reverse: None, + uids: None, + batch_uids: None, statuses: None, types: None, index_uids: None, - uids: None, canceled_by: None, before_enqueued_at: None, after_enqueued_at: None, @@ -227,6 +230,7 @@ impl MustStopProcessing { mod db_name { pub const ALL_TASKS: &str = "all-tasks"; pub const ALL_BATCHES: &str = "all-batches"; + pub const BATCH_TO_TASKS_MAPPING: &str = "batch-to-tasks-mapping"; pub const STATUS: &str = "status"; pub const KIND: &str = "kind"; pub const INDEX_TASKS: &str = "index-tasks"; @@ -323,30 +327,14 @@ pub struct IndexScheduler { /// The list of files referenced by the tasks pub(crate) file_store: FileStore, - // The main database, it contains all the tasks accessible by their Id. + /// The main database, it contains all the tasks accessible by their Id. pub(crate) all_tasks: Database>, - // Contains all the batches accessible by their Id. + /// Contains all the batches accessible by their Id. pub(crate) all_batches: Database>, - /// All the batches containing a task matching the selected status. - pub(crate) batch_status: Database, RoaringBitmapCodec>, - /// All the batches ids grouped by the kind of their task. - pub(crate) batch_kind: Database, RoaringBitmapCodec>, - /// Store the batches associated to an index. - pub(crate) batch_index_tasks: Database, - - /// Store the batches containing a task canceled by a task uid - pub(crate) batch_canceled_by: Database, - - /// Store the batches containing tasks which were enqueued at a specific date - pub(crate) batch_enqueued_at: Database, - - /// Store the batches containing finished tasks started at a specific date - pub(crate) batch_started_at: Database, - - /// Store the batches containing tasks finished at a specific date - pub(crate) batch_finished_at: Database, + /// Matches a batch id with the associated task ids. + pub(crate) batch_to_tasks_mapping: Database, /// All the tasks ids grouped by their status. // TODO we should not be able to serialize a `Status::Processing` in this database. @@ -355,19 +343,30 @@ pub struct IndexScheduler { pub(crate) kind: Database, RoaringBitmapCodec>, /// Store the tasks associated to an index. pub(crate) index_tasks: Database, - /// Store the tasks that were canceled by a task uid pub(crate) canceled_by: Database, - /// Store the task ids of tasks which were enqueued at a specific date pub(crate) enqueued_at: Database, - /// Store the task ids of finished tasks which started being processed at a specific date pub(crate) started_at: Database, - /// Store the task ids of tasks which finished at a specific date pub(crate) finished_at: Database, + /// All the batches containing a task matching the selected status. + pub(crate) batch_status: Database, RoaringBitmapCodec>, + /// All the batches ids grouped by the kind of their task. + pub(crate) batch_kind: Database, RoaringBitmapCodec>, + /// Store the batches associated to an index. + pub(crate) batch_index_tasks: Database, + /// Store the batches containing a task canceled by a task uid + pub(crate) batch_canceled_by: Database, + /// Store the batches containing tasks which were enqueued at a specific date + pub(crate) batch_enqueued_at: Database, + /// Store the batches containing finished tasks started at a specific date + pub(crate) batch_started_at: Database, + /// Store the batches containing tasks finished at a specific date + pub(crate) batch_finished_at: Database, + /// In charge of creating, opening, storing and returning indexes. pub(crate) index_mapper: IndexMapper, @@ -437,6 +436,7 @@ impl IndexScheduler { file_store: self.file_store.clone(), all_tasks: self.all_tasks, all_batches: self.all_batches, + batch_to_tasks_mapping: self.batch_to_tasks_mapping, // Tasks reverse index status: self.status, @@ -515,7 +515,7 @@ impl IndexScheduler { let env = unsafe { heed::EnvOpenOptions::new() - .max_dbs(19) + .max_dbs(20) .map_size(budget.task_db_size) .open(options.tasks_path) }?; @@ -527,6 +527,9 @@ impl IndexScheduler { let mut wtxn = env.write_txn()?; let all_tasks = env.create_database(&mut wtxn, Some(db_name::ALL_TASKS))?; let all_batches = env.create_database(&mut wtxn, Some(db_name::ALL_BATCHES))?; + let batch_to_tasks_mapping = + env.create_database(&mut wtxn, Some(db_name::BATCH_TO_TASKS_MAPPING))?; + let status = env.create_database(&mut wtxn, Some(db_name::STATUS))?; let kind = env.create_database(&mut wtxn, Some(db_name::KIND))?; let index_tasks = env.create_database(&mut wtxn, Some(db_name::INDEX_TASKS))?; @@ -551,6 +554,7 @@ impl IndexScheduler { file_store, all_tasks, all_batches, + batch_to_tasks_mapping, // Task reverse indexes status, kind, @@ -785,13 +789,32 @@ impl IndexScheduler { /// Return the task ids matched by the given query from the index scheduler's point of view. pub(crate) fn get_task_ids(&self, rtxn: &RoTxn, query: &Query) -> Result { let ProcessingTasks { - started_at: started_at_processing, processing: processing_tasks, .. + started_at: started_at_processing, + processing: processing_tasks, + batch_id: current_batch_processing, } = self.processing_tasks.read().unwrap().clone(); + let Query { + limit, + from, + reverse, + uids, + batch_uids, + statuses, + types, + index_uids, + canceled_by, + before_enqueued_at, + after_enqueued_at, + before_started_at, + after_started_at, + before_finished_at, + after_finished_at, + } = query; let mut tasks = self.all_task_ids(rtxn)?; - if let Some(from) = &query.from { - let range = if query.reverse.unwrap_or_default() { + if let Some(from) = from { + let range = if reverse.unwrap_or_default() { u32::MIN..*from } else { from.saturating_add(1)..u32::MAX @@ -799,7 +822,19 @@ impl IndexScheduler { tasks.remove_range(range); } - if let Some(status) = &query.statuses { + if let Some(batch_uids) = batch_uids { + let mut batch_tasks = RoaringBitmap::new(); + for batch_uid in batch_uids { + if Some(*batch_uid) == current_batch_processing { + batch_tasks |= &processing_tasks; + } else { + batch_tasks |= self.tasks_in_batch(rtxn, *batch_uid)?; + } + } + tasks &= batch_tasks; + } + + if let Some(status) = statuses { let mut status_tasks = RoaringBitmap::new(); for status in status { match status { @@ -816,12 +851,12 @@ impl IndexScheduler { tasks &= status_tasks; } - if let Some(uids) = &query.uids { + if let Some(uids) = uids { let uids = RoaringBitmap::from_iter(uids); tasks &= &uids; } - if let Some(canceled_by) = &query.canceled_by { + if let Some(canceled_by) = canceled_by { let mut all_canceled_tasks = RoaringBitmap::new(); for cancel_task_uid in canceled_by { if let Some(canceled_by_uid) = self.canceled_by.get(rtxn, cancel_task_uid)? { @@ -838,7 +873,7 @@ impl IndexScheduler { } } - if let Some(kind) = &query.types { + if let Some(kind) = types { let mut kind_tasks = RoaringBitmap::new(); for kind in kind { kind_tasks |= self.get_kind(rtxn, *kind)?; @@ -846,7 +881,7 @@ impl IndexScheduler { tasks &= &kind_tasks; } - if let Some(index) = &query.index_uids { + if let Some(index) = index_uids { let mut index_tasks = RoaringBitmap::new(); for index in index { index_tasks |= self.index_tasks(rtxn, index)?; @@ -876,25 +911,26 @@ impl IndexScheduler { filtered_processing_tasks.clear(); } }; - match (query.after_started_at, query.before_started_at) { + match (after_started_at, before_started_at) { (None, None) => (), (None, Some(before)) => { - clear_filtered_processing_tasks(Bound::Unbounded, Bound::Excluded(before)) + clear_filtered_processing_tasks(Bound::Unbounded, Bound::Excluded(*before)) } (Some(after), None) => { - clear_filtered_processing_tasks(Bound::Excluded(after), Bound::Unbounded) - } - (Some(after), Some(before)) => { - clear_filtered_processing_tasks(Bound::Excluded(after), Bound::Excluded(before)) + clear_filtered_processing_tasks(Bound::Excluded(*after), Bound::Unbounded) } + (Some(after), Some(before)) => clear_filtered_processing_tasks( + Bound::Excluded(*after), + Bound::Excluded(*before), + ), }; keep_tasks_within_datetimes( rtxn, &mut filtered_non_processing_tasks, self.started_at, - query.after_started_at, - query.before_started_at, + *after_started_at, + *before_started_at, )?; filtered_non_processing_tasks | filtered_processing_tasks }; @@ -903,23 +939,23 @@ impl IndexScheduler { rtxn, &mut tasks, self.enqueued_at, - query.after_enqueued_at, - query.before_enqueued_at, + *after_enqueued_at, + *before_enqueued_at, )?; keep_tasks_within_datetimes( rtxn, &mut tasks, self.finished_at, - query.after_finished_at, - query.before_finished_at, + *after_finished_at, + *before_finished_at, )?; - if let Some(limit) = query.limit { + if let Some(limit) = limit { tasks = if query.reverse.unwrap_or_default() { - tasks.into_iter().take(limit as usize).collect() + tasks.into_iter().take(*limit as usize).collect() } else { - tasks.into_iter().rev().take(limit as usize).collect() + tasks.into_iter().rev().take(*limit as usize).collect() }; } @@ -1295,7 +1331,6 @@ impl IndexScheduler { if processing.is_empty() { Ok((ret.collect(), total)) } else { - // TODO: We must re-insert the current processing batch somewhere in some way Ok(( ret.map(|batch| { if processing.contains(batch.uid) { @@ -1612,7 +1647,7 @@ impl IndexScheduler { let processed = self.processing_tasks.write().unwrap().stop_processing(); - self.write_batch(&mut wtxn, current_batch)?; + self.write_batch(&mut wtxn, current_batch, &processed.processing)?; #[cfg(test)] self.maybe_fail(tests::FailureLocation::CommittingWtxn)?; @@ -5420,6 +5455,8 @@ mod tests { ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- + ### Batch to tasks mapping: + ---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: @@ -5470,6 +5507,8 @@ mod tests { ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- + ### Batch to tasks mapping: + ---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap index e98f753ee..d1938e82d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap @@ -35,6 +35,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap index 4dc48d1f0..1784652c2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap @@ -47,6 +47,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap index f665ae94e..d3671cb4d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap @@ -43,6 +43,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap index b68dd1feb..92e484c93 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap @@ -46,6 +46,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap index f785eed48..8c6b6be65 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap @@ -31,6 +31,8 @@ enqueued [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap index 808a3b662..7406a373b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap @@ -34,6 +34,8 @@ enqueued [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap index 6e3713ceb..38925a23d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap @@ -36,6 +36,8 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap index 9cd11b76f..3b8a9a623 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap @@ -35,6 +35,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap index bd03ada39..5c1c3a765 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap @@ -32,6 +32,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap index a96abf42d..6b6af0667 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap @@ -32,6 +32,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap index 756edc2f2..6c8ead6b4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap @@ -44,6 +44,10 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap index d0388328b..ab62eb146 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap @@ -37,6 +37,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap index a96abf42d..6b6af0667 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap @@ -32,6 +32,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap index 0d0ddd63d..3b4d6db02 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap @@ -67,6 +67,14 @@ girafos: { number_of_documents: 0, field_distribution: {} } 4 {uid: 4, } 5 {uid: 5, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap index 189e84249..07ab97def 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap index 333505b3c..03484afe0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap index 6a445dd2f..c194af741 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap index 337f68862..668f9d5bf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap @@ -40,6 +40,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap index 60a3a9ad4..a26cb23aa 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap index dfb0af950..9765289fb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap index d629deb13..f8642736c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap @@ -43,6 +43,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap index ccf2f375e..deafc4c81 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap @@ -45,6 +45,10 @@ doggos [0,1,2,] 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap index 4d37e461d..198956185 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap index 5599779ca..4e9b84e52 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap index 05594e75a..84e037b05 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap @@ -38,6 +38,8 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap index d27aa6637..8f2bed791 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap index bfd425625..ade21179b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap @@ -39,6 +39,9 @@ doggos [0,1,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 49cfb5558..9a7b4686c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -39,6 +39,9 @@ doggos [0,1,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index 24ea830aa..60f71df9e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -44,6 +44,10 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [1,] failed [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap index 95911d88c..acfdb5e51 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap index 805b45c09..9748964e3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap index 333505b3c..03484afe0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index 6a46f7021..19881a91c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -36,6 +36,9 @@ doggos [0,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap index 189e84249..07ab97def 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap index 57fb1ff22..74e001fba 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap @@ -43,6 +43,10 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap index c418f7108..19d7a0c0a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap @@ -40,6 +40,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index 8a92b08c2..a6a036eee 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -56,6 +56,11 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,3,4,5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] failed [2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap index 80d76435e..093e693d1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap @@ -52,6 +52,10 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap index 056350b03..f6ff0721e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap index 04abc4309..03d239939 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap @@ -32,6 +32,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 1c4ccd6fe..154b1f35b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -36,6 +36,9 @@ catto [0,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap index 918ce228b..177307427 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap @@ -33,6 +33,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap index 918ce228b..177307427 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap @@ -33,6 +33,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap index 189e84249..07ab97def 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap index 189e84249..07ab97def 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap index 6a445dd2f..c194af741 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap index f958f60ed..e2cdc8d46 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap @@ -48,6 +48,11 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap index 340eed008..859e3b95d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap @@ -45,6 +45,10 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap index e7c904490..44b25b149 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap @@ -43,6 +43,10 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap index 76e87dca5..4eefe83c2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap @@ -40,6 +40,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap index 99f4d2aac..96d060a92 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap index 15f21e689..044791d61 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap index 8d1a6088a..eabfaed29 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap @@ -32,6 +32,8 @@ index_a [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap index 02c70b5b9..05bad8454 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap @@ -32,6 +32,8 @@ index_a [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap index 073661a22..bf009e414 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap @@ -35,6 +35,8 @@ index_b [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap index f2b1304b7..9c86652db 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap @@ -38,6 +38,8 @@ index_b [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index 590c2195a..17ed67aaf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -36,6 +36,9 @@ catto [0,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap index 04abc4309..03d239939 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap @@ -32,6 +32,8 @@ catto [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap index e45973d8a..31fb88530 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap @@ -43,6 +43,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap index dcf93ae65..7bafb0848 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap @@ -47,6 +47,10 @@ doggos: { number_of_documents: 0, field_distribution: {} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap index addd5fa0b..b2967a78e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap @@ -49,6 +49,11 @@ cattos: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap index 4d37e461d..198956185 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap index a61a566ac..5460e7476 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap @@ -35,6 +35,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap index 4baac782e..610282102 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap @@ -38,6 +38,8 @@ doggos [0,2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap index b1f5bdf62..915a39cb0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap @@ -44,6 +44,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap index 93bcdbc96..dfe92d4b3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap @@ -53,6 +53,12 @@ doggos: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap index 40866fe27..d92fa144c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap index d16440245..c75e0c550 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap @@ -39,6 +39,8 @@ doggos [0,1,2,3,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap index 5fe720fca..87f7406dd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap @@ -35,6 +35,8 @@ doggos [0,1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap index fbeeb76c3..86cb34f85 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap @@ -37,6 +37,8 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap index b0e395856..597e6704d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap @@ -47,6 +47,10 @@ doggos: { number_of_documents: 0, field_distribution: {} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap index 4c6e0dbc8..85cf963be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap @@ -50,6 +50,11 @@ doggos: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap index 502324155..d22441b0b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap @@ -51,6 +51,11 @@ whalo: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap index 7e04681ae..c6bf88bb0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggo [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap index 446635e88..cae2c4806 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap @@ -35,6 +35,8 @@ whalo [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap index 17d6e3c06..2346e5e68 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap @@ -38,6 +38,8 @@ whalo [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index 1e27e37de..b87a06b2b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -51,6 +51,11 @@ doggo: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] failed [2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap index d08e1e91c..7428155e9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap @@ -38,6 +38,8 @@ whalo [2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap index 65002e258..f5a544f18 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap @@ -41,6 +41,8 @@ whalo [3,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap index 6e7351489..62a7ae13a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap @@ -40,6 +40,8 @@ doggo [3,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap index e829d7511..91c15c3ee 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap @@ -46,6 +46,9 @@ a: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap index 57ed0b162..63e254e35 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap @@ -50,6 +50,10 @@ b: { number_of_documents: 0, field_distribution: {} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap index 5bb7a5e4a..529fa818e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap @@ -54,6 +54,11 @@ c: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap index 93a600529..9f47fbebd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap @@ -58,6 +58,12 @@ d: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap index a0713f706..74bf714b1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap @@ -66,6 +66,13 @@ d: { number_of_documents: 0, field_distribution: {} } 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap index 31d8e17ce..23cb14ac1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap @@ -61,6 +61,12 @@ d: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap index 0faa77720..a279d967f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap @@ -69,6 +69,14 @@ d: { number_of_documents: 0, field_distribution: {} } 4 {uid: 4, } 5 {uid: 5, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap index d9797e688..e3be49476 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap @@ -74,6 +74,15 @@ d: { number_of_documents: 0, field_distribution: {} } 5 {uid: 5, } 6 {uid: 6, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,6,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap index f86b42f84..2014150bb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap @@ -63,6 +63,12 @@ d: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap index 93a600529..9f47fbebd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap @@ -58,6 +58,12 @@ d: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index a5f9c698a..df676be58 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -67,6 +67,13 @@ d: { number_of_documents: 0, field_distribution: {} } 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] failed [4,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap index 93a600529..9f47fbebd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap @@ -58,6 +58,12 @@ d: { number_of_documents: 0, field_distribution: {} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap index 11676902e..88e7db81c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap @@ -35,6 +35,8 @@ doggo [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap index 76397487f..50d9a972a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap @@ -40,6 +40,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 7bd8fe151..72dc1bfae 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -43,6 +43,10 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [2,3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap index 804508a4b..42d528498 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap @@ -43,6 +43,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap index 11676902e..88e7db81c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap @@ -35,6 +35,8 @@ doggo [1,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap index 76397487f..50d9a972a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap @@ -40,6 +40,9 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index 6ed2345c0..71e834518 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -41,6 +41,10 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap index 678a16a18..4be93852c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap @@ -38,6 +38,8 @@ doggo [2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap index a56083a2c..834dd2e74 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap @@ -45,6 +45,9 @@ doggo [2,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap index a4b8c1684..f5d93baa3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap @@ -41,6 +41,8 @@ doggo [2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap index 40dae1197..d9e7733d4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap @@ -41,6 +41,8 @@ doggo [2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap index dfba0ed23..10149200c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap @@ -61,6 +61,10 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,2,3,4,5,6,7,8,9,10,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap index ae2297eeb..fdbef5f31 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap @@ -58,6 +58,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap index bdb6e01ff..0260edea5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap index 4d37e461d..198956185 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap index 61505d069..6e4179250 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap @@ -58,6 +58,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap index 5739c8105..c66a50d47 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap @@ -88,6 +88,19 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 9 {uid: 9, } 10 {uid: 10, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +7 [7,] +8 [8,] +9 [9,] +10 [10,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap index b806721fd..8440c7113 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap @@ -73,6 +73,14 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 4 {uid: 4, } 5 {uid: 5, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap index e7740fcf1..45eb1b027 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap index 40866fe27..d92fa144c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index 579b2246d..9600955a0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -54,6 +54,9 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap index 29d40f34d..06cc66a60 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap index 11c6d42de..74111aac3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index 2dfa22ba1..2fe601741 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -81,6 +81,18 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 8 {uid: 8, } 9 {uid: 9, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +7 [7,] +8 [8,] +9 [9,] +---------------------------------------------------------------------- ### Batches Status: failed [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index 5c4954e33..bc6fecb2a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -66,6 +66,13 @@ doggos [0,1,2,3,4,5,6,7,8,9,] 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: failed [0,1,2,3,4,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap index 686a1d431..8ee0a9b12 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index 4336145b7..0e225ea8d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -59,6 +59,10 @@ doggos: { number_of_documents: 9, field_distribution: {"doggo": 9, "id": 9} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [1,] failed [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index a5154407d..ac3c29fcb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -54,6 +54,9 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap index 7e96a40c7..1a0f4a54d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap @@ -58,6 +58,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap index 38c797bf6..feec34884 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap @@ -61,6 +61,10 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,2,3,4,5,6,7,8,9,10,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap index bdb6e01ff..0260edea5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap index 4d37e461d..198956185 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap index 37a09f901..f0f74b328 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap @@ -40,6 +40,8 @@ doggos [0,1,2,3,4,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index d786f8b22..953297977 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -55,6 +55,12 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "id": 2} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +1 [2,] +2 [3,] +3 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [1,3,] failed [0,2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index 1e2b68bc3..502fefbfd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -45,6 +45,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 3227bdf8f..95c76085b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -52,6 +52,11 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +1 [2,] +2 [3,] +---------------------------------------------------------------------- ### Batches Status: succeeded [1,] failed [0,2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index d0fc43f43..e29c5e90c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -49,6 +49,10 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,] +1 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [1,] failed [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap index 83309739d..3ea317c43 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap @@ -36,6 +36,8 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap index 3029a930b..651b3cf5b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap @@ -41,6 +41,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index ef1ec1880..6fca659b1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -45,6 +45,10 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] failed [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index d7b5c6f02..18baf7207 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -48,6 +48,11 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] failed [1,2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap index cac51c8c0..9df0f214d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap @@ -36,6 +36,8 @@ doggos [0,1,2,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap index c90477046..cfe528340 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap @@ -41,6 +41,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 3b16d875b..7ed185b9b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -45,6 +45,10 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] failed [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap index a738c59cb..1e6cff26c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap @@ -42,6 +42,8 @@ doggos [0,1,2,3,4,5,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index dbe7f75a5..577938932 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -57,6 +57,12 @@ doggos: { number_of_documents: 4, field_distribution: {"doggo": 4, "paw": 4} } 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,4,5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [2,3,] failed [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index 7ee25125b..e807035a9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -47,6 +47,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: failed [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index 2cbfaa5cf..9e718473f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -50,6 +50,10 @@ doggos: { number_of_documents: 0, field_distribution: {} } 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: failed [0,1,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index 7a6dc3ead..ec4449e29 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -54,6 +54,11 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "paw": 1} } 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [2,] failed [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap index df0b40cab..de01fce5a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap @@ -42,6 +42,8 @@ doggos [0,1,2,3,4,5,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index 0a4e65ea9..b4d54f680 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -57,6 +57,12 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "doggoid": 5} 2 {uid: 2, } 3 {uid: 3, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,4,5,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,2,3,] failed [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap index 20d5216a5..8f4ceb94e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap @@ -47,6 +47,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index a044ca823..350ace217 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -51,6 +51,10 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} 0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] failed [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index 238636df6..f908e7a8c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -54,6 +54,11 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "doggoid": 2} 1 {uid: 1, } 2 {uid: 2, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,2,] failed [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap index e91fda83f..355ef8821 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap index 9e8ce7422..c3ff75f58 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap @@ -55,6 +55,9 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap index 6289818cc..88d9addb8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap index b9d1a914b..40b51ed14 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap @@ -82,6 +82,18 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 8 {uid: 8, } 9 {uid: 9, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +7 [7,] +8 [8,] +9 [9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap index ea13f7d97..62ea510d1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap @@ -67,6 +67,13 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap index 5a03a2aa8..7aeb7da17 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap index 0239ded3a..a922b0595 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap @@ -55,6 +55,9 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,1,2,3,4,5,6,7,8,9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap index 2bd63c492..fea75fb83 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap index 9222896d5..2f8a5e4d8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap @@ -82,6 +82,18 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 8 {uid: 8, } 9 {uid: 9, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +7 [7,] +8 [8,] +9 [9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap index 3f599636b..ca1f46581 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap @@ -67,6 +67,13 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap index 47e701bc9..6575b835d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap @@ -50,6 +50,8 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap index f9eb836ef..453ff8c61 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap @@ -82,6 +82,18 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } 8 {uid: 8, } 9 {uid: 9, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +5 [5,] +6 [6,] +7 [7,] +8 [8,] +9 [9,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap index 323cb7552..1e06b6dce 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap @@ -67,6 +67,13 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } 3 {uid: 3, } 4 {uid: 4, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +4 [4,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap index ac6e7b258..dd81f33e7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap @@ -32,6 +32,8 @@ doggos [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap index f2108b7b0..d889e5706 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap @@ -37,6 +37,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, } ---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- ### Batches Status: succeeded [0,] ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap index 02c70b5b9..05bad8454 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap @@ -32,6 +32,8 @@ index_a [0,] ---------------------------------------------------------------------- ### All Batches: ---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- ### Batches Status: ---------------------------------------------------------------------- ### Batches Kind: diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index d8f4f0521..d557d3e2e 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -94,7 +94,12 @@ impl IndexScheduler { Ok(self.all_batches.get(rtxn, &batch_id)?) } - pub(crate) fn write_batch(&self, wtxn: &mut RwTxn, batch: CachedBatch) -> Result<()> { + pub(crate) fn write_batch( + &self, + wtxn: &mut RwTxn, + batch: CachedBatch, + tasks: &RoaringBitmap, + ) -> Result<()> { self.all_batches.put( wtxn, &batch.uid, @@ -104,6 +109,7 @@ impl IndexScheduler { finished_at: Some(batch.finished_at), }, )?; + self.batch_to_tasks_mapping.put(wtxn, &batch.uid, tasks)?; for status in batch.statuses { self.update_batch_status(wtxn, status, |bitmap| { @@ -233,6 +239,11 @@ impl IndexScheduler { Ok(()) } + /// Returns the whole set of tasks that belongs to this batch. + pub(crate) fn tasks_in_batch(&self, rtxn: &RoTxn, batch_id: BatchId) -> Result { + Ok(self.batch_to_tasks_mapping.get(rtxn, &batch_id)?.unwrap_or_default()) + } + /// Returns the whole set of tasks that belongs to this index. pub(crate) fn index_tasks(&self, rtxn: &RoTxn, index: &str) -> Result { Ok(self.index_tasks.get(rtxn, index)?.unwrap_or_default()) @@ -558,7 +569,6 @@ impl IndexScheduler { let Task { uid, - /// We should iterate over the list of batch to ensure this task is effectively in the right batch batch_uid, enqueued_at, started_at, @@ -570,6 +580,14 @@ impl IndexScheduler { kind, } = task; assert_eq!(uid, task.uid); + if let Some(ref batch) = batch_uid { + assert!(self + .batch_to_tasks_mapping + .get(&rtxn, batch) + .unwrap() + .unwrap() + .contains(uid)); + } if let Some(task_index_uid) = &task_index_uid { assert!(self .index_tasks diff --git a/crates/meilisearch/src/routes/tasks.rs b/crates/meilisearch/src/routes/tasks.rs index 7cdad308e..cd82a6a18 100644 --- a/crates/meilisearch/src/routes/tasks.rs +++ b/crates/meilisearch/src/routes/tasks.rs @@ -3,6 +3,7 @@ use actix_web::{web, HttpRequest, HttpResponse}; use deserr::actix_web::AwebQueryParameter; use deserr::Deserr; use index_scheduler::{IndexScheduler, Query, TaskId}; +use meilisearch_types::batches::BatchId; use meilisearch_types::deserr::query_params::Param; use meilisearch_types::deserr::DeserrQueryParamError; use meilisearch_types::error::deserr_codes::*; @@ -44,6 +45,9 @@ pub struct TasksFilterQuery { #[deserr(default, error = DeserrQueryParamError)] pub reverse: Option>, + #[deserr(default, error = DeserrQueryParamError)] + pub batch_uids: OptionStarOrList, + #[deserr(default, error = DeserrQueryParamError)] pub uids: OptionStarOrList, #[deserr(default, error = DeserrQueryParamError)] @@ -75,6 +79,7 @@ impl TasksFilterQuery { limit: Some(self.limit.0), from: self.from.as_deref().copied(), reverse: self.reverse.as_deref().copied(), + batch_uids: self.batch_uids.merge_star_and_none(), statuses: self.statuses.merge_star_and_none(), types: self.types.merge_star_and_none(), index_uids: self.index_uids.map(|x| x.to_string()).merge_star_and_none(), @@ -96,6 +101,7 @@ impl TaskDeletionOrCancelationQuery { self, TaskDeletionOrCancelationQuery { uids: OptionStarOrList::None, + batch_uids: OptionStarOrList::None, canceled_by: OptionStarOrList::None, types: OptionStarOrList::None, statuses: OptionStarOrList::None, @@ -115,9 +121,11 @@ impl TaskDeletionOrCancelationQuery { #[deserr(error = DeserrQueryParamError, rename_all = camelCase, deny_unknown_fields)] pub struct TaskDeletionOrCancelationQuery { #[deserr(default, error = DeserrQueryParamError)] - pub uids: OptionStarOrList, + pub uids: OptionStarOrList, + #[deserr(default, error = DeserrQueryParamError)] + pub batch_uids: OptionStarOrList, #[deserr(default, error = DeserrQueryParamError)] - pub canceled_by: OptionStarOrList, + pub canceled_by: OptionStarOrList, #[deserr(default, error = DeserrQueryParamError)] pub types: OptionStarOrList, #[deserr(default, error = DeserrQueryParamError)] @@ -145,6 +153,7 @@ impl TaskDeletionOrCancelationQuery { limit: None, from: None, reverse: None, + batch_uids: self.batch_uids.merge_star_and_none(), statuses: self.statuses.merge_star_and_none(), types: self.types.merge_star_and_none(), index_uids: self.index_uids.map(|x| x.to_string()).merge_star_and_none(), @@ -484,7 +493,7 @@ mod tests { // Stars are allowed in date fields as well let params = "afterEnqueuedAt=*&beforeStartedAt=*&afterFinishedAt=*&beforeFinishedAt=*&afterStartedAt=*&beforeEnqueuedAt=*"; let query = deserr_query_params::(params).unwrap(); - snapshot!(format!("{:?}", query), @"TaskDeletionOrCancelationQuery { uids: None, canceled_by: None, types: None, statuses: None, index_uids: None, after_enqueued_at: Star, before_enqueued_at: Star, after_started_at: Star, before_started_at: Star, after_finished_at: Star, before_finished_at: Star }"); + snapshot!(format!("{:?}", query), @"TaskDeletionOrCancelationQuery { uids: None, batch_uids: None, canceled_by: None, types: None, statuses: None, index_uids: None, after_enqueued_at: Star, before_enqueued_at: Star, after_started_at: Star, before_started_at: Star, after_finished_at: Star, before_finished_at: Star }"); } { let params = "afterFinishedAt=2021"; @@ -704,20 +713,20 @@ mod tests { { let params = "from=12&limit=15&indexUids=toto,tata-78&statuses=succeeded,enqueued&afterEnqueuedAt=2012-04-23&uids=1,2,3"; let query = deserr_query_params::(params).unwrap(); - snapshot!(format!("{:?}", query), @r###"TasksFilterQuery { limit: Param(15), from: Some(Param(12)), reverse: None, uids: List([1, 2, 3]), canceled_by: None, types: None, statuses: List([Succeeded, Enqueued]), index_uids: List([IndexUid("toto"), IndexUid("tata-78")]), after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"###); + snapshot!(format!("{:?}", query), @r###"TasksFilterQuery { limit: Param(15), from: Some(Param(12)), reverse: None, batch_uids: None, uids: List([1, 2, 3]), canceled_by: None, types: None, statuses: List([Succeeded, Enqueued]), index_uids: List([IndexUid("toto"), IndexUid("tata-78")]), after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"###); } { // Stars should translate to `None` in the query // Verify value of the default limit let params = "indexUids=*&statuses=succeeded,*&afterEnqueuedAt=2012-04-23&uids=1,2,3"; let query = deserr_query_params::(params).unwrap(); - snapshot!(format!("{:?}", query), @"TasksFilterQuery { limit: Param(20), from: None, reverse: None, uids: List([1, 2, 3]), canceled_by: None, types: None, statuses: Star, index_uids: Star, after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); + snapshot!(format!("{:?}", query), @"TasksFilterQuery { limit: Param(20), from: None, reverse: None, batch_uids: None, uids: List([1, 2, 3]), canceled_by: None, types: None, statuses: Star, index_uids: Star, after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); } { // Stars should also translate to `None` in task deletion/cancelation queries let params = "indexUids=*&statuses=succeeded,*&afterEnqueuedAt=2012-04-23&uids=1,2,3"; let query = deserr_query_params::(params).unwrap(); - snapshot!(format!("{:?}", query), @"TaskDeletionOrCancelationQuery { uids: List([1, 2, 3]), canceled_by: None, types: None, statuses: Star, index_uids: Star, after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); + snapshot!(format!("{:?}", query), @"TaskDeletionOrCancelationQuery { uids: List([1, 2, 3]), batch_uids: None, canceled_by: None, types: None, statuses: Star, index_uids: Star, after_enqueued_at: Other(2012-04-24 0:00:00.0 +00:00:00), before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); } { // Star in from not allowed @@ -738,7 +747,7 @@ mod tests { let err = deserr_query_params::(params).unwrap_err(); snapshot!(meili_snap::json_string!(err), @r###" { - "message": "Unknown parameter `from`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `from`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" @@ -751,7 +760,7 @@ mod tests { let err = deserr_query_params::(params).unwrap_err(); snapshot!(meili_snap::json_string!(err), @r###" { - "message": "Unknown parameter `limit`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `limit`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" @@ -771,7 +780,7 @@ mod tests { let params = "statuses=*"; let query = deserr_query_params::(params).unwrap(); assert!(!query.is_empty()); - snapshot!(format!("{query:?}"), @"TaskDeletionOrCancelationQuery { uids: None, canceled_by: None, types: None, statuses: Star, index_uids: None, after_enqueued_at: None, before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); + snapshot!(format!("{query:?}"), @"TaskDeletionOrCancelationQuery { uids: None, batch_uids: None, canceled_by: None, types: None, statuses: Star, index_uids: None, after_enqueued_at: None, before_enqueued_at: None, after_started_at: None, before_started_at: None, after_finished_at: None, before_finished_at: None }"); } } } diff --git a/crates/meilisearch/tests/tasks/errors.rs b/crates/meilisearch/tests/tasks/errors.rs index 0e2966c8f..2ff497db9 100644 --- a/crates/meilisearch/tests/tasks/errors.rs +++ b/crates/meilisearch/tests/tasks/errors.rs @@ -222,7 +222,7 @@ async fn task_bad_limit() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Unknown parameter `limit`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `limit`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" @@ -233,7 +233,7 @@ async fn task_bad_limit() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Unknown parameter `limit`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `limit`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" @@ -260,7 +260,7 @@ async fn task_bad_from() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Unknown parameter `from`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `from`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" @@ -271,7 +271,7 @@ async fn task_bad_from() { snapshot!(code, @"400 Bad Request"); snapshot!(json_string!(response), @r###" { - "message": "Unknown parameter `from`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `from`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" From ad9763ffcdb4d9d11f5145a40be0ca856c34f383 Mon Sep 17 00:00:00 2001 From: Tamo Date: Mon, 18 Nov 2024 13:40:17 +0100 Subject: [PATCH 04/22] copy multiple task query tests to batches. Currently, they fails --- crates/index-scheduler/src/lib.rs | 419 ++++++++++++++++++++++++++++++ 1 file changed, 419 insertions(+) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 4d242d677..d761e0a7c 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -4138,6 +4138,425 @@ mod tests { snapshot!(snapshot_bitmap(&tasks), @"[1,]"); } + #[test] + fn query_batches_from_and_limit() { + let (index_scheduler, mut handle) = IndexScheduler::test(true, vec![]); + + let kind = index_creation_task("doggo", "bone"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "registered_the_first_task"); + let kind = index_creation_task("whalo", "plankton"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "registered_the_second_task"); + let kind = index_creation_task("catto", "his_own_vomit"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "registered_the_third_task"); + + handle.advance_n_successful_batches(3); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "processed_all_tasks"); + + let rtxn = index_scheduler.env.read_txn().unwrap(); + let query = Query { limit: Some(0), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query { limit: Some(1), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + + let query = Query { limit: Some(2), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); + + let query = Query { from: Some(1), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); + + let query = Query { from: Some(2), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[0,1,2,]"); + + let query = Query { from: Some(1), limit: Some(1), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[1,]"); + + let query = Query { from: Some(1), limit: Some(2), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); + } + + #[test] + fn query_batches_simple() { + let start_time = OffsetDateTime::now_utc(); + + let (index_scheduler, mut handle) = + IndexScheduler::test(true, vec![(3, FailureLocation::InsideProcessBatch)]); + + let kind = index_creation_task("catto", "mouse"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + let kind = index_creation_task("doggo", "sheep"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + let kind = index_creation_task("whalo", "fish"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); + + handle.advance_till([Start, BatchCreated]); + + let rtxn = index_scheduler.env.read_txn().unwrap(); + + let query = Query { statuses: Some(vec![Status::Processing]), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[0,]"); // only the processing batch in the first tick + + let query = Query { statuses: Some(vec![Status::Enqueued]), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); // only the enqueued batches in the first tick + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Processing]), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + snapshot!(snapshot_bitmap(&batches), @"[0,1,2,]"); // both enqueued and processing tasks in the first tick + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Processing]), + after_started_at: Some(start_time), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both enqueued and processing tasks in the first tick, but limited to those with a started_at + // that comes after the start of the test, which should excludes the enqueued tasks + snapshot!(snapshot_bitmap(&batches), @"[0,]"); + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Processing]), + before_started_at: Some(start_time), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both enqueued and processing tasks in the first tick, but limited to those with a started_at + // that comes before the start of the test, which should excludes all of them + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Processing]), + after_started_at: Some(start_time), + before_started_at: Some(start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both enqueued and processing tasks in the first tick, but limited to those with a started_at + // that comes after the start of the test and before one minute after the start of the test, + // which should exclude the enqueued tasks and include the only processing task + snapshot!(snapshot_bitmap(&batches), @"[0,]"); + + handle.advance_till([ + InsideProcessBatch, + InsideProcessBatch, + ProcessBatchSucceeded, + AfterProcessing, + Start, + BatchCreated, + ]); + + let rtxn = index_scheduler.env.read_txn().unwrap(); + + let second_start_time = OffsetDateTime::now_utc(); + + let query = Query { + statuses: Some(vec![Status::Succeeded, Status::Processing]), + after_started_at: Some(start_time), + before_started_at: Some(start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both succeeded and processing tasks in the first tick, but limited to those with a started_at + // that comes after the start of the test and before one minute after the start of the test, + // which should include all tasks + snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); + + let query = Query { + statuses: Some(vec![Status::Succeeded, Status::Processing]), + before_started_at: Some(start_time), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both succeeded and processing tasks in the first tick, but limited to those with a started_at + // that comes before the start of the test, which should exclude all tasks + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Succeeded, Status::Processing]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // both succeeded and processing tasks in the first tick, but limited to those with a started_at + // that comes after the start of the second part of the test and before one minute after the + // second start of the test, which should exclude all tasks + snapshot!(snapshot_bitmap(&batches), @"[]"); + + // now we make one more batch, the started_at field of the new tasks will be past `second_start_time` + handle.advance_till([ + InsideProcessBatch, + InsideProcessBatch, + ProcessBatchSucceeded, + AfterProcessing, + Start, + BatchCreated, + ]); + + let rtxn = index_scheduler.env.read_txn().unwrap(); + + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // we run the same query to verify that, and indeed find that the last task is matched + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + + let query = Query { + statuses: Some(vec![Status::Enqueued, Status::Succeeded, Status::Processing]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // enqueued, succeeded, or processing tasks started after the second part of the test, should + // again only return the last task + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + + handle.advance_till([ProcessBatchFailed, AfterProcessing]); + let rtxn = index_scheduler.read_txn().unwrap(); + + // now the last task should have failed + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "end"); + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // so running the last query should return nothing + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query { + statuses: Some(vec![Status::Failed]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // but the same query on failed tasks should return the last task + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + + let query = Query { + statuses: Some(vec![Status::Failed]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // but the same query on failed tasks should return the last task + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + + let query = Query { + statuses: Some(vec![Status::Failed]), + uids: Some(vec![1]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // same query but with an invalid uid + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query { + statuses: Some(vec![Status::Failed]), + uids: Some(vec![2]), + after_started_at: Some(second_start_time), + before_started_at: Some(second_start_time + Duration::minutes(1)), + ..Default::default() + }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // same query but with a valid uid + snapshot!(snapshot_bitmap(&batches), @"[2,]"); + } + + #[test] + fn query_batches_special_rules() { + let (index_scheduler, mut handle) = + IndexScheduler::test(true, vec![(3, FailureLocation::InsideProcessBatch)]); + + let kind = index_creation_task("catto", "mouse"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + let kind = index_creation_task("doggo", "sheep"); + let _task = index_scheduler.register(kind, None, false).unwrap(); + let kind = KindWithContent::IndexSwap { + swaps: vec![IndexSwap { indexes: ("catto".to_owned(), "doggo".to_owned()) }], + }; + let _task = index_scheduler.register(kind, None, false).unwrap(); + let kind = KindWithContent::IndexSwap { + swaps: vec![IndexSwap { indexes: ("catto".to_owned(), "whalo".to_owned()) }], + }; + let _task = index_scheduler.register(kind, None, false).unwrap(); + + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); + + handle.advance_till([Start, BatchCreated]); + + let rtxn = index_scheduler.env.read_txn().unwrap(); + + let query = Query { index_uids: Some(vec!["catto".to_owned()]), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // only the first task associated with catto is returned, the indexSwap tasks are excluded! + snapshot!(snapshot_bitmap(&batches), @"[0,]"); + + let query = Query { index_uids: Some(vec!["catto".to_owned()]), ..Default::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes( + &rtxn, + &query, + &AuthFilter::with_allowed_indexes( + vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), + ), + ) + .unwrap(); + // we have asked for only the tasks associated with catto, but are only authorized to retrieve the tasks + // associated with doggo -> empty result + snapshot!(snapshot_bitmap(&batches), @"[]"); + + let query = Query::default(); + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes( + &rtxn, + &query, + &AuthFilter::with_allowed_indexes( + vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), + ), + ) + .unwrap(); + // we asked for all the tasks, but we are only authorized to retrieve the doggo tasks + // -> only the index creation of doggo should be returned + snapshot!(snapshot_bitmap(&batches), @"[1,]"); + + let query = Query::default(); + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes( + &rtxn, + &query, + &AuthFilter::with_allowed_indexes( + vec![ + IndexUidPattern::new_unchecked("catto"), + IndexUidPattern::new_unchecked("doggo"), + ] + .into_iter() + .collect(), + ), + ) + .unwrap(); + // we asked for all the tasks, but we are only authorized to retrieve the doggo and catto tasks + // -> all tasks except the swap of catto with whalo are returned + snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); + + let query = Query::default(); + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // we asked for all the tasks with all index authorized -> all tasks returned + snapshot!(snapshot_bitmap(&batches), @"[0,1,2,3,]"); + } + + #[test] + fn query_batches_canceled_by() { + let (index_scheduler, mut handle) = + IndexScheduler::test(true, vec![(3, FailureLocation::InsideProcessBatch)]); + + let kind = index_creation_task("catto", "mouse"); + let _ = index_scheduler.register(kind, None, false).unwrap(); + let kind = index_creation_task("doggo", "sheep"); + let _ = index_scheduler.register(kind, None, false).unwrap(); + let kind = KindWithContent::IndexSwap { + swaps: vec![IndexSwap { indexes: ("catto".to_owned(), "doggo".to_owned()) }], + }; + let _task = index_scheduler.register(kind, None, false).unwrap(); + + handle.advance_n_successful_batches(1); + let kind = KindWithContent::TaskCancelation { + query: "test_query".to_string(), + tasks: [0, 1, 2, 3].into_iter().collect(), + }; + let task_cancelation = index_scheduler.register(kind, None, false).unwrap(); + handle.advance_n_successful_batches(1); + + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); + + let rtxn = index_scheduler.read_txn().unwrap(); + let query = Query { canceled_by: Some(vec![task_cancelation.uid]), ..Query::default() }; + let (batches, _) = index_scheduler + .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .unwrap(); + // 0 is not returned because it was not canceled, 3 is not returned because it is the uid of the + // taskCancelation itself + snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); + + let query = Query { canceled_by: Some(vec![task_cancelation.uid]), ..Query::default() }; + let (batches, _) = index_scheduler + .get_task_ids_from_authorized_indexes( + &rtxn, + &query, + &AuthFilter::with_allowed_indexes( + vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), + ), + ) + .unwrap(); + // Return only 1 because the user is not authorized to see task 2 + snapshot!(snapshot_bitmap(&batches), @"[1,]"); + } + #[test] fn fail_in_process_batch_for_index_creation() { let (index_scheduler, mut handle) = From 15eefa4fcc6e8f7651c8022d6952b3466f7876b7 Mon Sep 17 00:00:00 2001 From: Tamo Date: Mon, 18 Nov 2024 16:53:55 +0100 Subject: [PATCH 05/22] fixes a lot of small issue, the test about the cancellation is still failing --- crates/index-scheduler/src/batch.rs | 128 +++++------ crates/index-scheduler/src/insta_snapshot.rs | 5 +- crates/index-scheduler/src/lib.rs | 210 +++++++++++------- .../processed_all_tasks.snap | 90 ++++++++ .../registered_the_first_task.snap | 54 +++++ .../registered_the_second_task.snap | 57 +++++ .../registered_the_third_task.snap | 60 +++++ .../lib.rs/query_batches_simple/end.snap | 91 ++++++++ .../lib.rs/query_batches_simple/start.snap | 60 +++++ .../after-processing-everything.snap | 102 +++++++++ .../query_batches_special_rules/start.snap | 63 ++++++ crates/index-scheduler/src/utils.rs | 92 ++++---- crates/meilisearch-types/src/tasks.rs | 5 - 13 files changed, 821 insertions(+), 196 deletions(-) create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index d64e2657a..0130e9bfe 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -24,7 +24,6 @@ use std::fs::{self, File}; use std::io::BufWriter; use dump::IndexMetadata; -use meilisearch_types::batches::BatchId; use meilisearch_types::error::Code; use meilisearch_types::heed::{RoTxn, RwTxn}; use meilisearch_types::milli::documents::{obkv_to_object, DocumentsBatchReader}; @@ -45,7 +44,7 @@ use time::OffsetDateTime; use uuid::Uuid; use crate::autobatcher::{self, BatchKind}; -use crate::utils::{self, swap_index_uid_in_task}; +use crate::utils::{self, swap_index_uid_in_task, ProcessingBatch}; use crate::{Error, IndexScheduler, MustStopProcessing, ProcessingTasks, Result, TaskId}; /// Represents a combination of tasks that can all be processed at the same time. @@ -280,22 +279,24 @@ impl IndexScheduler { rtxn: &RoTxn, index_uid: String, batch: BatchKind, - batch_id: BatchId, + current_batch: &mut ProcessingBatch, must_create_index: bool, ) -> Result> { match batch { BatchKind::DocumentClear { ids } => Ok(Some(Batch::IndexOperation { op: IndexOperation::DocumentClear { - tasks: self.get_existing_tasks_with_batch_id(rtxn, batch_id, ids)?, + tasks: self.get_existing_tasks_with_processing_batch( + rtxn, + current_batch, + ids, + )?, index_uid, }, must_create_index, })), BatchKind::DocumentEdition { id } => { - let task = self - .get_task(rtxn, id)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id); + let mut task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); match &task.kind { KindWithContent::DocumentEdition { index_uid, .. } => { Ok(Some(Batch::IndexOperation { @@ -310,7 +311,11 @@ impl IndexScheduler { } } BatchKind::DocumentOperation { method, operation_ids, .. } => { - let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, operation_ids)?; + let tasks = self.get_existing_tasks_with_processing_batch( + rtxn, + current_batch, + operation_ids, + )?; let primary_key = tasks .iter() .find_map(|task| match task.kind { @@ -357,7 +362,11 @@ impl IndexScheduler { })) } BatchKind::DocumentDeletion { deletion_ids, includes_by_filter: _ } => { - let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, deletion_ids)?; + let tasks = self.get_existing_tasks_with_processing_batch( + rtxn, + current_batch, + deletion_ids, + )?; Ok(Some(Batch::IndexOperation { op: IndexOperation::DocumentDeletion { index_uid, tasks }, @@ -365,7 +374,11 @@ impl IndexScheduler { })) } BatchKind::Settings { settings_ids, .. } => { - let tasks = self.get_existing_tasks_with_batch_id(rtxn, batch_id, settings_ids)?; + let tasks = self.get_existing_tasks_with_processing_batch( + rtxn, + current_batch, + settings_ids, + )?; let mut settings = Vec::new(); for task in &tasks { @@ -388,7 +401,7 @@ impl IndexScheduler { rtxn, index_uid, BatchKind::Settings { settings_ids, allow_index_creation }, - batch_id, + current_batch, must_create_index, )? .unwrap() @@ -404,7 +417,7 @@ impl IndexScheduler { rtxn, index_uid, BatchKind::DocumentClear { ids: other }, - batch_id, + current_batch, must_create_index, )? .unwrap() @@ -437,7 +450,7 @@ impl IndexScheduler { rtxn, index_uid.clone(), BatchKind::Settings { settings_ids, allow_index_creation }, - batch_id, + current_batch, must_create_index, )?; @@ -450,7 +463,7 @@ impl IndexScheduler { primary_key, operation_ids, }, - batch_id, + current_batch, must_create_index, )?; @@ -488,10 +501,8 @@ impl IndexScheduler { } } BatchKind::IndexCreation { id } => { - let task = self - .get_task(rtxn, id)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id); + let mut task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); let (index_uid, primary_key) = match &task.kind { KindWithContent::IndexCreation { index_uid, primary_key } => { (index_uid.clone(), primary_key.clone()) @@ -501,10 +512,8 @@ impl IndexScheduler { Ok(Some(Batch::IndexCreation { index_uid, primary_key, task })) } BatchKind::IndexUpdate { id } => { - let task = self - .get_task(rtxn, id)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id); + let mut task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); let primary_key = match &task.kind { KindWithContent::IndexUpdate { primary_key, .. } => primary_key.clone(), _ => unreachable!(), @@ -514,13 +523,11 @@ impl IndexScheduler { BatchKind::IndexDeletion { ids } => Ok(Some(Batch::IndexDeletion { index_uid, index_has_been_created: must_create_index, - tasks: self.get_existing_tasks_with_batch_id(rtxn, batch_id, ids)?, + tasks: self.get_existing_tasks_with_processing_batch(rtxn, current_batch, ids)?, })), BatchKind::IndexSwap { id } => { - let task = self - .get_task(rtxn, id)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id); + let mut task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); Ok(Some(Batch::IndexSwap { task })) } } @@ -533,11 +540,16 @@ impl IndexScheduler { /// 4. We get the *next* dump to process. /// 5. We get the *next* tasks to process for a specific index. #[tracing::instrument(level = "trace", skip(self, rtxn), target = "indexing::scheduler")] - pub(crate) fn create_next_batch(&self, rtxn: &RoTxn) -> Result> { + pub(crate) fn create_next_batch( + &self, + rtxn: &RoTxn, + ) -> Result> { #[cfg(test)] self.maybe_fail(crate::tests::FailureLocation::InsideCreateBatch)?; let batch_id = self.next_batch_id(rtxn)?; + let mut current_batch = ProcessingBatch::new(batch_id); + let enqueued = &self.get_status(rtxn, Status::Enqueued)?; let to_cancel = self.get_kind(rtxn, Kind::TaskCancelation)? & enqueued; @@ -547,63 +559,51 @@ impl IndexScheduler { // We must *not* reset the processing tasks before calling this method. // Displaying the `batch_id` would make a strange error message since this task cancelation is going to // replace the canceled batch. It's better to avoid mentioning it in the error message. - let ProcessingTasks { started_at, batch_id: _, processing } = + let ProcessingTasks { batch: previous_batch, processing } = &*self.processing_tasks.read().unwrap(); + let mut task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); return Ok(Some(( Batch::TaskCancelation { - task: self - .get_task(rtxn, task_id)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id), - previous_started_at: *started_at, + task, + // We should never be in a case where we don't have a previous_batch, but let's not crash if it happens + previous_started_at: previous_batch + .as_ref() + .map_or_else(OffsetDateTime::now_utc, |batch| batch.started_at), previous_processing_tasks: processing.clone(), }, - batch_id, + current_batch, ))); } // 2. we get the next task to delete let to_delete = self.get_kind(rtxn, Kind::TaskDeletion)? & enqueued; if !to_delete.is_empty() { - let tasks = self - .get_existing_tasks(rtxn, to_delete)? - .into_iter() - .map(|task| task.with_batch_id(batch_id)) - .collect(); - return Ok(Some((Batch::TaskDeletions(tasks), batch_id))); + let mut tasks = self.get_existing_tasks(rtxn, to_delete)?; + current_batch.processing(&mut tasks); + return Ok(Some((Batch::TaskDeletions(tasks), current_batch))); } // 3. we batch the snapshot. let to_snapshot = self.get_kind(rtxn, Kind::SnapshotCreation)? & enqueued; if !to_snapshot.is_empty() { - return Ok(Some(( - Batch::SnapshotCreation( - self.get_existing_tasks(rtxn, to_snapshot)? - .into_iter() - .map(|task| task.with_batch_id(batch_id)) - .collect(), - ), - batch_id, - ))); + let mut tasks = self.get_existing_tasks(rtxn, to_snapshot)?; + current_batch.processing(&mut tasks); + return Ok(Some((Batch::SnapshotCreation(tasks), current_batch))); } // 4. we batch the dumps. let to_dump = self.get_kind(rtxn, Kind::DumpCreation)? & enqueued; if let Some(to_dump) = to_dump.min() { - return Ok(Some(( - Batch::Dump( - self.get_task(rtxn, to_dump)? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id), - ), - batch_id, - ))); + let mut task = self.get_task(rtxn, to_dump)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); + return Ok(Some((Batch::Dump(task), current_batch))); } // 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 task = - self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?.with_batch_id(batch_id); + let mut task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; + current_batch.processing(Some(&mut task)); // 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 @@ -613,7 +613,7 @@ impl IndexScheduler { index_name } else { assert!(matches!(&task.kind, KindWithContent::IndexSwap { swaps } if swaps.is_empty())); - return Ok(Some((Batch::IndexSwap { task }, batch_id))); + return Ok(Some((Batch::IndexSwap { task }, current_batch))); }; let index_already_exists = self.index_mapper.exists(rtxn, index_name)?; @@ -649,10 +649,10 @@ impl IndexScheduler { rtxn, index_name.to_string(), batchkind, - batch_id, + &mut current_batch, create_index, )? - .map(|batch| (batch, batch_id))); + .map(|batch| (batch, current_batch))); } // If we found no tasks then we were notified for something that got autobatched diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index 2ca12e1ee..da0d90baa 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -68,7 +68,10 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { let processing = processing_tasks.read().unwrap().clone(); snap.push_str(&format!("### Autobatching Enabled = {autobatching_enabled}\n")); - snap.push_str(&format!("### Processing batch {:?}:\n", processing.batch_id)); + snap.push_str(&format!( + "### Processing batch {:?}:\n", + processing.batch.map(|batch| batch.uid) + )); snap.push_str(&snapshot_bitmap(&processing.processing)); snap.push_str("\n----------------------------------------------------------------------\n"); diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index d761e0a7c..5ba93f020 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -71,7 +71,7 @@ use utils::{filter_out_references_to_newer_tasks, keep_tasks_within_datetimes, m use uuid::Uuid; use crate::index_mapper::IndexMapper; -use crate::utils::{check_index_swap_validity, clamp_to_page_size, CachedBatch}; +use crate::utils::{check_index_swap_validity, clamp_to_page_size, ProcessingBatch}; pub(crate) type BEI128 = I128; @@ -164,10 +164,7 @@ impl Query { #[derive(Debug, Clone)] struct ProcessingTasks { - /// The date and time at which the indexation started. - started_at: OffsetDateTime, - /// The id of the batch processing - batch_id: Option, + batch: Option, /// The list of tasks ids that are currently running. processing: RoaringBitmap, } @@ -175,30 +172,19 @@ struct ProcessingTasks { impl ProcessingTasks { /// Creates an empty `ProcessingAt` struct. fn new() -> ProcessingTasks { - ProcessingTasks { - started_at: OffsetDateTime::now_utc(), - batch_id: None, - processing: RoaringBitmap::new(), - } + ProcessingTasks { batch: None, processing: RoaringBitmap::new() } } /// Stores the currently processing tasks, and the date time at which it started. - fn start_processing( - &mut self, - started_at: OffsetDateTime, - batch_id: BatchId, - processing: RoaringBitmap, - ) { - self.started_at = started_at; - self.batch_id = Some(batch_id); + fn start_processing(&mut self, processing_batch: ProcessingBatch, processing: RoaringBitmap) { + self.batch = Some(processing_batch); self.processing = processing; } /// Set the processing tasks to an empty list fn stop_processing(&mut self) -> Self { Self { - started_at: self.started_at, - batch_id: self.batch_id.take(), + batch: std::mem::take(&mut self.batch), processing: std::mem::take(&mut self.processing), } } @@ -788,11 +774,8 @@ impl IndexScheduler { /// Return the task ids matched by the given query from the index scheduler's point of view. pub(crate) fn get_task_ids(&self, rtxn: &RoTxn, query: &Query) -> Result { - let ProcessingTasks { - started_at: started_at_processing, - processing: processing_tasks, - batch_id: current_batch_processing, - } = self.processing_tasks.read().unwrap().clone(); + let ProcessingTasks { batch: processing_batch, processing: processing_tasks } = + self.processing_tasks.read().unwrap().clone(); let Query { limit, from, @@ -825,7 +808,7 @@ impl IndexScheduler { if let Some(batch_uids) = batch_uids { let mut batch_tasks = RoaringBitmap::new(); for batch_uid in batch_uids { - if Some(*batch_uid) == current_batch_processing { + if Some(*batch_uid) == processing_batch.as_ref().map(|batch| batch.uid) { batch_tasks |= &processing_tasks; } else { batch_tasks |= self.tasks_in_batch(rtxn, *batch_uid)?; @@ -899,13 +882,15 @@ impl IndexScheduler { // special case for Processing tasks // A closure that clears the filtered_processing_tasks if their started_at date falls outside the given bounds - let mut clear_filtered_processing_tasks = + let clear_filtered_processing_tasks = |start: Bound, end: Bound| { let start = map_bound(start, |b| b.unix_timestamp_nanos()); let end = map_bound(end, |b| b.unix_timestamp_nanos()); let is_within_dates = RangeBounds::contains( &(start, end), - &started_at_processing.unix_timestamp_nanos(), + &processing_batch + .map_or_else(OffsetDateTime::now_utc, |batch| batch.started_at) + .unix_timestamp_nanos(), ); if !is_within_dates { filtered_processing_tasks.clear(); @@ -963,42 +948,59 @@ impl IndexScheduler { } /// Return the batch ids matched by the given query from the index scheduler's point of view. - pub(crate) fn get_batch_ids(&self, rtxn: &RoTxn, query: &Query) -> Result { - let ProcessingTasks { - started_at: started_at_processing, - processing: processing_batches, - batch_id, - } = self.processing_tasks.read().unwrap().clone(); - + pub(crate) fn get_batch_ids( + &self, + rtxn: &RoTxn, + processing: &ProcessingTasks, + query: &Query, + ) -> Result { let mut batches = self.all_batch_ids(rtxn)?; + if let Some(batch_id) = processing.batch.as_ref().map(|batch| batch.uid) { + batches.insert(batch_id); + } if let Some(from) = &query.from { batches.remove_range(from.saturating_add(1)..); } + if let Some(batch_uids) = &query.batch_uids { + let batches_uids = RoaringBitmap::from_iter(batch_uids); + batches &= batches_uids; + } + if let Some(status) = &query.statuses { let mut status_batches = RoaringBitmap::new(); for status in status { - // TODO: We can't retrieve anything around processing batches so we can get rid of a lot of code here match status { // special case for Processing batches Status::Processing => { - if let Some(batch_id) = batch_id { + if let Some(batch_id) = processing.batch.as_ref().map(|batch| batch.uid) { status_batches.insert(batch_id); } } + // Enqueued tasks are not stored in batches + Status::Enqueued => (), status => status_batches |= &self.get_batch_status(rtxn, *status)?, }; } if !status.contains(&Status::Processing) { - batches -= &processing_batches; + if let Some(ref batch) = processing.batch { + batches.remove(batch.uid); + } } batches &= status_batches; } - if let Some(uids) = &query.uids { - let uids = RoaringBitmap::from_iter(uids); - batches &= &uids; + if let Some(task_uids) = &query.uids { + let mut batches_by_task_uids = RoaringBitmap::new(); + for task_uid in task_uids { + if let Some(task) = self.get_task(rtxn, *task_uid)? { + if let Some(batch_uid) = task.batch_uid { + batches_by_task_uids.insert(batch_uid); + } + } + } + batches &= batches_by_task_uids; } if let Some(canceled_by) = &query.canceled_by { @@ -1022,6 +1024,13 @@ impl IndexScheduler { let mut kind_batches = RoaringBitmap::new(); for kind in kind { kind_batches |= self.get_batch_kind(rtxn, *kind)?; + if let Some(uid) = processing + .batch + .as_ref() + .and_then(|batch| batch.kinds.contains(kind).then_some(batch.uid)) + { + kind_batches.insert(uid); + } } batches &= &kind_batches; } @@ -1030,6 +1039,13 @@ impl IndexScheduler { let mut index_batches = RoaringBitmap::new(); for index in index { index_batches |= self.index_batches(rtxn, index)?; + if let Some(uid) = processing + .batch + .as_ref() + .and_then(|batch| batch.indexes.contains(index).then_some(batch.uid)) + { + index_batches.insert(uid); + } } batches &= &index_batches; } @@ -1040,7 +1056,7 @@ impl IndexScheduler { // Once we have filtered the two subsets, we put them back together and assign it back to `batches`. batches = { let (mut filtered_non_processing_batches, mut filtered_processing_batches) = - (&batches - &processing_batches, &batches & &processing_batches); + (&batches - &processing.processing, &batches & &processing.processing); // special case for Processing batches // A closure that clears the filtered_processing_batches if their started_at date falls outside the given bounds @@ -1050,7 +1066,11 @@ impl IndexScheduler { let end = map_bound(end, |b| b.unix_timestamp_nanos()); let is_within_dates = RangeBounds::contains( &(start, end), - &started_at_processing.unix_timestamp_nanos(), + &processing + .batch + .as_ref() + .map_or_else(OffsetDateTime::now_utc, |batch| batch.started_at) + .unix_timestamp_nanos(), ); if !is_within_dates { filtered_processing_batches.clear(); @@ -1220,32 +1240,50 @@ impl IndexScheduler { query: &Query, filters: &meilisearch_auth::AuthFilter, ) -> Result<(RoaringBitmap, u64)> { + let processing = self.processing_tasks.read().unwrap().clone(); + // compute all batches matching the filter by ignoring the limits, to find the number of batches matching // the filter. // As this causes us to compute the filter twice it is slightly inefficient, but doing it this way spares // us from modifying the underlying implementation, and the performance remains sufficient. // Should this change, we would modify `get_batch_ids` to directly return the number of matching batches. - let total_batches = self.get_batch_ids(rtxn, &query.clone().without_limits())?; - let mut batches = self.get_batch_ids(rtxn, query)?; + let total_batches = + self.get_batch_ids(rtxn, &processing, &query.clone().without_limits())?; + let mut batches = self.get_batch_ids(rtxn, &processing, query)?; // If the query contains a list of index uid or there is a finite list of authorized indexes, - // then we must exclude all the kinds that aren't associated to one and only one index. + // then we must exclude all the batches that only contains tasks associated to multiple indexes. + // This works because we don't autobatch tasks associated to multiple indexes with tasks associated + // to a single index. e.g: IndexSwap cannot be batched with IndexCreation. if query.index_uids.is_some() || !filters.all_indexes_authorized() { for kind in enum_iterator::all::().filter(|kind| !kind.related_to_one_index()) { batches -= self.get_kind(rtxn, kind)?; + if let Some(batch) = processing.batch.as_ref() { + if batch.kinds.contains(&kind) { + batches.remove(batch.uid); + } + } } } // Any task that is internally associated with a non-authorized index // must be discarded. + // This works because currently batches cannot contains tasks from multiple indexes at the same time. if !filters.all_indexes_authorized() { - let all_indexes_iter = self.index_tasks.iter(rtxn)?; + let all_indexes_iter = self.batch_index_tasks.iter(rtxn)?; for result in all_indexes_iter { let (index, index_tasks) = result?; if !filters.is_index_authorized(index) { batches -= index_tasks; } } + if let Some(batch) = processing.batch.as_ref() { + for index in &batch.indexes { + if !filters.is_index_authorized(index) { + batches.remove(batch.uid); + } + } + } } Ok((batches, total_batches.len())) @@ -1276,20 +1314,22 @@ impl IndexScheduler { let tasks = self.get_existing_tasks(&rtxn, tasks.take(query.limit.unwrap_or(u32::MAX) as usize))?; - let ProcessingTasks { started_at, batch_id, processing } = + let ProcessingTasks { batch, processing } = self.processing_tasks.read().map_err(|_| Error::CorruptedTaskQueue)?.clone(); let ret = tasks.into_iter(); - if processing.is_empty() { + if processing.is_empty() || batch.is_none() { Ok((ret.collect(), total)) } else { + // Safe because we ensured there was a batch in the previous branch + let batch = batch.unwrap(); Ok(( ret.map(|task| { if processing.contains(task.uid) { Task { status: Status::Processing, - batch_uid: batch_id, - started_at: Some(started_at), + batch_uid: Some(batch.uid), + started_at: Some(batch.started_at), ..task } } else { @@ -1318,31 +1358,14 @@ impl IndexScheduler { ) -> Result<(Vec, u64)> { let rtxn = self.env.read_txn()?; - let (tasks, total) = self.get_batch_ids_from_authorized_indexes(&rtxn, &query, filters)?; - let tasks = self.get_existing_batches( + let (batches, total) = + self.get_batch_ids_from_authorized_indexes(&rtxn, &query, filters)?; + let batches = self.get_existing_batches( &rtxn, - tasks.into_iter().rev().take(query.limit.unwrap_or(u32::MAX) as usize), + batches.into_iter().rev().take(query.limit.unwrap_or(u32::MAX) as usize), )?; - let ProcessingTasks { started_at, batch_id, processing } = - self.processing_tasks.read().map_err(|_| Error::CorruptedTaskQueue)?.clone(); - - let ret = tasks.into_iter(); - if processing.is_empty() { - Ok((ret.collect(), total)) - } else { - Ok(( - ret.map(|batch| { - if processing.contains(batch.uid) { - Batch { started_at, ..batch } - } else { - batch - } - }) - .collect(), - total, - )) - } + Ok((batches, total)) } /// Register a new task in the scheduler. @@ -1510,7 +1533,7 @@ impl IndexScheduler { } let rtxn = self.env.read_txn().map_err(Error::HeedTransaction)?; - let (batch, batch_id) = + let (batch, mut processing_batch) = match self.create_next_batch(&rtxn).map_err(|e| Error::CreateBatch(Box::new(e)))? { Some(batch) => batch, None => return Ok(TickOutcome::WaitForSignal), @@ -1521,11 +1544,14 @@ impl IndexScheduler { // 1. store the starting date with the bitmap of processing tasks. let ids = batch.ids(); let processed_tasks = ids.len(); - let started_at = OffsetDateTime::now_utc(); // We reset the must_stop flag to be sure that we don't stop processing tasks self.must_stop_processing.reset(); - self.processing_tasks.write().unwrap().start_processing(started_at, batch_id, ids.clone()); + self.processing_tasks + .write() + .unwrap() + // We can clone the processing batch here because we don't want its modification to affect the view of the processing batches + .start_processing(processing_batch.clone(), ids.clone()); #[cfg(test)] self.breakpoint(Breakpoint::BatchCreated); @@ -1549,7 +1575,6 @@ impl IndexScheduler { let mut wtxn = self.env.write_txn().map_err(Error::HeedTransaction)?; let finished_at = OffsetDateTime::now_utc(); - let mut current_batch = CachedBatch::new(batch_id, started_at, finished_at); match res { Ok(tasks) => { #[cfg(test)] @@ -1560,7 +1585,7 @@ impl IndexScheduler { #[allow(unused_variables)] for (i, mut task) in tasks.into_iter().enumerate() { - task.started_at = Some(started_at); + task.started_at = Some(processing_batch.started_at); task.finished_at = Some(finished_at); #[cfg(test)] @@ -1577,7 +1602,7 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; - current_batch.update(&task); + processing_batch.update(&task); } tracing::info!("A batch of tasks was successfully completed with {success} successful tasks and {failure} failed tasks."); } @@ -1625,9 +1650,9 @@ impl IndexScheduler { let mut task = self .get_task(&wtxn, id) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))? - .ok_or(Error::CorruptedTaskQueue)? - .with_batch_id(batch_id); - task.started_at = Some(started_at); + .ok_or(Error::CorruptedTaskQueue)?; + task.batch_uid = Some(processing_batch.uid); + task.started_at = Some(processing_batch.started_at); task.finished_at = Some(finished_at); task.status = Status::Failed; task.error = Some(error.clone()); @@ -1640,14 +1665,14 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; - current_batch.update(&task); + processing_batch.update(&task); } } } let processed = self.processing_tasks.write().unwrap().stop_processing(); - self.write_batch(&mut wtxn, current_batch, &processed.processing)?; + self.write_batch(&mut wtxn, processing_batch, &processed.processing, finished_at)?; #[cfg(test)] self.maybe_fail(tests::FailureLocation::CommittingWtxn)?; @@ -4229,7 +4254,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) .unwrap(); - snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); // only the enqueued batches in the first tick + snapshot!(snapshot_bitmap(&batches), @"[]"); // The batches don't contains any enqueued tasks let query = Query { statuses: Some(vec![Status::Enqueued, Status::Processing]), @@ -4238,7 +4263,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) .unwrap(); - snapshot!(snapshot_bitmap(&batches), @"[0,1,2,]"); // both enqueued and processing tasks in the first tick + snapshot!(snapshot_bitmap(&batches), @"[0,]"); // both enqueued and processing tasks in the first tick let query = Query { statuses: Some(vec![Status::Enqueued, Status::Processing]), @@ -4469,6 +4494,19 @@ mod tests { // associated with doggo -> empty result snapshot!(snapshot_bitmap(&batches), @"[]"); + drop(rtxn); + // We're going to advance and process all the batches for the next query to actually hit the db + handle.advance_till([ + InsideProcessBatch, + InsideProcessBatch, + ProcessBatchSucceeded, + AfterProcessing, + ]); + handle.advance_one_successful_batch(); + handle.advance_n_failed_batches(2); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "after-processing-everything"); + let rtxn = index_scheduler.env.read_txn().unwrap(); + let query = Query::default(); let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes( diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap new file mode 100644 index 000000000..d22441b0b --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap @@ -0,0 +1,90 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("plankton") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("plankton") }} +2 {uid: 2, batch_uid: 2, status: succeeded, details: { primary_key: Some("his_own_vomit") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("his_own_vomit") }} +---------------------------------------------------------------------- +### Status: +enqueued [] +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Index Tasks: +catto [2,] +doggo [0,] +whalo [1,] +---------------------------------------------------------------------- +### Index Mapper: +catto: { number_of_documents: 0, field_distribution: {} } +doggo: { number_of_documents: 0, field_distribution: {} } +whalo: { number_of_documents: 0, field_distribution: {} } + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [2,] +doggo [0,] +whalo [1,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap new file mode 100644 index 000000000..c6bf88bb0 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap @@ -0,0 +1,54 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, status: enqueued, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} +---------------------------------------------------------------------- +### Status: +enqueued [0,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Index Tasks: +doggo [0,] +---------------------------------------------------------------------- +### Index Mapper: + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Started At: +---------------------------------------------------------------------- +### Finished At: +---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap new file mode 100644 index 000000000..cae2c4806 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap @@ -0,0 +1,57 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, status: enqueued, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} +1 {uid: 1, status: enqueued, details: { primary_key: Some("plankton") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("plankton") }} +---------------------------------------------------------------------- +### Status: +enqueued [0,1,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,] +---------------------------------------------------------------------- +### Index Tasks: +doggo [0,] +whalo [1,] +---------------------------------------------------------------------- +### Index Mapper: + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Started At: +---------------------------------------------------------------------- +### Finished At: +---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap new file mode 100644 index 000000000..2346e5e68 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap @@ -0,0 +1,60 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, status: enqueued, details: { primary_key: Some("bone") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("bone") }} +1 {uid: 1, status: enqueued, details: { primary_key: Some("plankton") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("plankton") }} +2 {uid: 2, status: enqueued, details: { primary_key: Some("his_own_vomit") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("his_own_vomit") }} +---------------------------------------------------------------------- +### Status: +enqueued [0,1,2,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Index Tasks: +catto [2,] +doggo [0,] +whalo [1,] +---------------------------------------------------------------------- +### Index Mapper: + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Started At: +---------------------------------------------------------------------- +### Finished At: +---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap new file mode 100644 index 000000000..b87a06b2b --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap @@ -0,0 +1,91 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { primary_key: Some("fish") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("fish") }} +---------------------------------------------------------------------- +### Status: +enqueued [] +succeeded [0,1,] +failed [2,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,] +doggo [1,] +whalo [2,] +---------------------------------------------------------------------- +### Index Mapper: +catto: { number_of_documents: 0, field_distribution: {} } +doggo: { number_of_documents: 0, field_distribution: {} } + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +failed [2,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +doggo [1,] +whalo [2,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap new file mode 100644 index 000000000..7428155e9 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap @@ -0,0 +1,60 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, status: enqueued, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, status: enqueued, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, status: enqueued, details: { primary_key: Some("fish") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("fish") }} +---------------------------------------------------------------------- +### Status: +enqueued [0,1,2,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,] +doggo [1,] +whalo [2,] +---------------------------------------------------------------------- +### Index Mapper: + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Started At: +---------------------------------------------------------------------- +### Finished At: +---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap new file mode 100644 index 000000000..625017e91 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap @@ -0,0 +1,102 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, batch_uid: 1, status: succeeded, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, batch_uid: 2, status: failed, error: ResponseError { code: 200, message: "Planned failure for tests.", error_code: "internal", error_type: "internal", error_link: "https://docs.meilisearch.com/errors#internal" }, details: { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }} +3 {uid: 3, batch_uid: 3, status: failed, error: ResponseError { code: 200, message: "Index `whalo` not found.", error_code: "index_not_found", error_type: "invalid_request", error_link: "https://docs.meilisearch.com/errors#index_not_found" }, details: { swaps: [IndexSwap { indexes: ("catto", "whalo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "whalo") }] }} +---------------------------------------------------------------------- +### Status: +enqueued [] +succeeded [0,1,] +failed [2,3,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,] +"indexSwap" [2,3,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,2,3,] +doggo [1,2,] +whalo [3,] +---------------------------------------------------------------------- +### Index Mapper: +catto: { number_of_documents: 0, field_distribution: {} } +doggo: { number_of_documents: 0, field_distribution: {} } + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +2 {uid: 2, } +3 {uid: 3, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [1,] +2 [2,] +3 [3,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +failed [2,3,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +"indexSwap" [2,3,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,2,3,] +doggo [1,2,] +whalo [3,] +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap new file mode 100644 index 000000000..f5a544f18 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap @@ -0,0 +1,63 @@ +--- +source: crates/index-scheduler/src/lib.rs +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, status: enqueued, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, status: enqueued, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, status: enqueued, details: { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }} +3 {uid: 3, status: enqueued, details: { swaps: [IndexSwap { indexes: ("catto", "whalo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "whalo") }] }} +---------------------------------------------------------------------- +### Status: +enqueued [0,1,2,3,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,] +"indexSwap" [2,3,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,2,3,] +doggo [1,2,] +whalo [3,] +---------------------------------------------------------------------- +### Index Mapper: + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Started At: +---------------------------------------------------------------------- +### Finished At: +---------------------------------------------------------------------- +### All Batches: +---------------------------------------------------------------------- +### Batch to tasks mapping: +---------------------------------------------------------------------- +### Batches Status: +---------------------------------------------------------------------- +### Batches Kind: +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Canceled By: + +---------------------------------------------------------------------- +### Batches Enqueued At: +---------------------------------------------------------------------- +### Batches Started At: +---------------------------------------------------------------------- +### Batches Finished At: +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index d557d3e2e..8ffef39f3 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -11,52 +11,65 @@ use meilisearch_types::tasks::{Details, IndexSwap, Kind, KindWithContent, Status use roaring::{MultiOps, RoaringBitmap}; use time::OffsetDateTime; -use crate::{Error, IndexScheduler, ProcessingTasks, Result, Task, TaskId, BEI128}; +use crate::{Error, IndexScheduler, Result, Task, TaskId, BEI128}; /// This structure contains all the information required to write a batch in the database without reading the tasks. /// It'll stay in RAM so it must be small. -pub(crate) struct CachedBatch { - uid: BatchId, - statuses: HashSet, - kinds: HashSet, - indexes: HashSet, - canceled_by: HashSet, - oldest_enqueued_at: Option, - earliest_enqueued_at: Option, - started_at: OffsetDateTime, - finished_at: OffsetDateTime, +#[derive(Debug, Clone)] +pub(crate) struct ProcessingBatch { + pub uid: BatchId, + pub statuses: HashSet, + pub kinds: HashSet, + pub indexes: HashSet, + pub canceled_by: HashSet, + pub oldest_enqueued_at: Option, + pub earliest_enqueued_at: Option, + pub started_at: OffsetDateTime, } -impl CachedBatch { - pub fn new(uid: BatchId, started_at: OffsetDateTime, finished_at: OffsetDateTime) -> Self { +impl ProcessingBatch { + pub fn new(uid: BatchId) -> Self { + // At the beginning, all the tasks are processing + let mut statuses = HashSet::default(); + statuses.insert(Status::Processing); + Self { uid, - statuses: HashSet::default(), + statuses, kinds: HashSet::default(), indexes: HashSet::default(), canceled_by: HashSet::default(), oldest_enqueued_at: None, earliest_enqueued_at: None, - started_at, - finished_at, + started_at: OffsetDateTime::now_utc(), } } + /// Remove the Processing status and update the real statuses of the tasks. pub fn update(&mut self, task: &Task) { + self.statuses.clear(); self.statuses.insert(task.status); - self.kinds.insert(task.kind.as_kind()); - self.indexes.extend(task.indexes().iter().map(|s| s.to_string())); - if let Some(canceled_by) = task.canceled_by { - self.canceled_by.insert(canceled_by); + } + + /// 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) { + for task in tasks.into_iter() { + task.batch_uid = Some(self.uid); + // We don't store the statuses since they're all enqueued. + self.kinds.insert(task.kind.as_kind()); + self.indexes.extend(task.indexes().iter().map(|s| s.to_string())); + if let Some(canceled_by) = task.canceled_by { + self.canceled_by.insert(canceled_by); + } + self.oldest_enqueued_at = + Some(self.oldest_enqueued_at.map_or(task.enqueued_at, |oldest_enqueued_at| { + task.enqueued_at.min(oldest_enqueued_at) + })); + self.earliest_enqueued_at = + Some(self.earliest_enqueued_at.map_or(task.enqueued_at, |earliest_enqueued_at| { + task.enqueued_at.max(earliest_enqueued_at) + })); } - self.oldest_enqueued_at = - Some(self.oldest_enqueued_at.map_or(task.enqueued_at, |oldest_enqueued_at| { - task.enqueued_at.min(oldest_enqueued_at) - })); - self.earliest_enqueued_at = - Some(self.earliest_enqueued_at.map_or(task.enqueued_at, |earliest_enqueued_at| { - task.enqueued_at.max(earliest_enqueued_at) - })); } } @@ -97,17 +110,14 @@ impl IndexScheduler { pub(crate) fn write_batch( &self, wtxn: &mut RwTxn, - batch: CachedBatch, + batch: ProcessingBatch, tasks: &RoaringBitmap, + finished_at: OffsetDateTime, ) -> Result<()> { self.all_batches.put( wtxn, &batch.uid, - &Batch { - uid: batch.uid, - started_at: batch.started_at, - finished_at: Some(batch.finished_at), - }, + &Batch { uid: batch.uid, started_at: batch.started_at, finished_at: Some(finished_at) }, )?; self.batch_to_tasks_mapping.put(wtxn, &batch.uid, tasks)?; @@ -135,25 +145,27 @@ impl IndexScheduler { insert_task_datetime(wtxn, self.batch_enqueued_at, enqueued_at, batch.uid)?; } insert_task_datetime(wtxn, self.batch_started_at, batch.started_at, batch.uid)?; - insert_task_datetime(wtxn, self.batch_finished_at, batch.finished_at, batch.uid)?; + insert_task_datetime(wtxn, self.batch_finished_at, finished_at, batch.uid)?; Ok(()) } /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a /// `CorruptedTaskQueue` error will be throwed. - pub(crate) fn get_existing_tasks_with_batch_id( + pub(crate) fn get_existing_tasks_with_processing_batch( &self, rtxn: &RoTxn, - batch_id: BatchId, + processing_batch: &mut ProcessingBatch, tasks: impl IntoIterator, ) -> Result> { tasks .into_iter() .map(|task_id| { - self.get_task(rtxn, task_id) - .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)) - .map(|task| task.with_batch_id(batch_id)) + let mut task = self + .get_task(rtxn, task_id) + .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)); + processing_batch.processing(&mut task); + task }) .collect::>() } diff --git a/crates/meilisearch-types/src/tasks.rs b/crates/meilisearch-types/src/tasks.rs index 3485962d1..f5875225a 100644 --- a/crates/meilisearch-types/src/tasks.rs +++ b/crates/meilisearch-types/src/tasks.rs @@ -62,11 +62,6 @@ impl Task { } } - pub fn with_batch_id(mut self, batch_id: TaskId) -> Self { - self.batch_uid = Some(batch_id); - self - } - /// Return the list of indexes updated by this tasks. pub fn indexes(&self) -> Vec<&str> { self.kind.indexes() From 1fcb9526f59820c3dbb66a79d670e51e02ee75c8 Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 01:47:42 +0100 Subject: [PATCH 06/22] fix the task cancelation --- crates/index-scheduler/src/batch.rs | 79 +++++--------- crates/index-scheduler/src/insta_snapshot.rs | 5 - crates/index-scheduler/src/lib.rs | 100 +++++++++++------- .../cancel_processed.snap | 38 +++++-- .../initial_tasks_enqueued.snap | 4 +- .../aborted_indexation.snap | 4 +- .../cancel_mix_of_tasks/cancel_processed.snap | 51 +++++++-- .../first_task_processed.snap | 4 +- ...rocessing_second_task_cancel_enqueued.snap | 4 +- .../after_dump_register.snap | 4 +- .../cancel_processed.snap | 37 +++++-- .../cancel_registered.snap | 4 +- .../aborted_indexation.snap | 4 +- .../cancel_processed.snap | 39 +++++-- .../cancel_task_registered.snap | 4 +- .../initial_task_processing.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../cancel_processed.snap | 5 +- .../initial_task_processed.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../document_addition/after_register.snap | 4 +- .../after_the_batch_creation.snap | 4 +- .../once_everything_is_processed.snap | 4 +- .../after_processing_the_batch.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../before_index_creation.snap | 4 +- .../both_task_succeeded.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../1.snap | 4 +- .../2.snap | 4 +- .../after_failing_the_deletion.snap | 4 +- .../after_last_successful_addition.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../document_addition_batch_created.snap | 4 +- .../document_addition_failed.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../after_adding_the_documents.snap | 4 +- .../after_adding_the_settings.snap | 4 +- .../after_removing_the_documents.snap | 5 +- .../registered_the_document_deletions.snap | 4 +- ...red_the_setting_and_document_addition.snap | 4 +- .../after_register.snap | 4 +- .../index_creation_failed.snap | 4 +- .../after_batch_succeeded.snap | 4 +- .../after_failing_to_commit.snap | 4 +- ...eeded_but_index_scheduler_not_updated.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../task_successfully_processed.snap | 4 +- .../Intel to kefir succeeds.snap | 4 +- .../lib.rs/import_vectors/Intel to kefir.snap | 4 +- .../import_vectors/adding Intel succeeds.snap | 4 +- .../import_vectors/after adding Intel.snap | 4 +- ...ter_registering_settings_task_vectors.snap | 4 +- .../settings_update_processed_vectors.snap | 4 +- .../after_batch_creation.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../index_creation_failed.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../processed_the_first_task.snap | 4 +- .../processed_the_second_task.snap | 4 +- .../processed_the_third_task.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../first.snap | 4 +- .../fourth.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_fourth_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../second.snap | 4 +- .../third.snap | 4 +- .../query_batches_canceled_by/start.snap | 86 +++++++++++++++ .../processed_all_tasks.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../lib.rs/query_batches_simple/end.snap | 4 +- .../lib.rs/query_batches_simple/start.snap | 4 +- .../after-processing-everything.snap | 4 +- .../query_batches_special_rules/start.snap | 4 +- .../lib.rs/query_tasks_canceled_by/start.snap | 48 +++++++-- .../processed_all_tasks.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../registered_the_second_task.snap | 4 +- .../registered_the_third_task.snap | 4 +- .../lib.rs/query_tasks_simple/end.snap | 4 +- .../lib.rs/query_tasks_simple/start.snap | 4 +- .../query_tasks_special_rules/start.snap | 4 +- ...everything_is_successfully_registered.snap | 4 +- .../lib.rs/swap_indexes/create_a.snap | 4 +- .../lib.rs/swap_indexes/create_b.snap | 4 +- .../lib.rs/swap_indexes/create_c.snap | 4 +- .../lib.rs/swap_indexes/create_d.snap | 4 +- .../swap_indexes/first_swap_processed.snap | 4 +- .../swap_indexes/first_swap_registered.snap | 4 +- .../swap_indexes/second_swap_processed.snap | 4 +- .../third_empty_swap_processed.snap | 4 +- .../swap_indexes/two_swaps_registered.snap | 4 +- .../after_the_index_creation.snap | 4 +- .../first_swap_failed.snap | 4 +- .../initial_tasks_processed.snap | 4 +- .../initial_tasks_enqueued.snap | 4 +- .../initial_tasks_processed.snap | 4 +- .../task_deletion_processed.snap | 4 +- .../after_registering_the_task_deletion.snap | 4 +- .../initial_tasks_enqueued.snap | 4 +- .../initial_tasks_processed.snap | 4 +- .../task_deletion_processed.snap | 4 +- .../initial_tasks_enqueued.snap | 4 +- .../task_deletion_done.snap | 4 +- .../task_deletion_enqueued.snap | 4 +- .../task_deletion_processing.snap | 4 +- .../after_processing_the_10_tasks.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../processed_the_first_task.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../five_tasks_processed.snap | 4 +- .../processed_the_first_task.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../after_processing_the_10_tasks.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../five_tasks_processed.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../only_first_task_failed.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../processed_the_first_task.snap | 4 +- .../registered_the_first_task.snap | 4 +- .../after_registering_the_5_tasks.snap | 4 +- .../fifth_task_succeeds.snap | 4 +- .../first_and_second_task_fails.snap | 4 +- .../fourth_task_fails.snap | 4 +- .../third_task_succeeds.snap | 4 +- .../after_registering_the_3_tasks.snap | 4 +- .../only_first_task_succeed.snap | 4 +- .../second_task_fails.snap | 4 +- .../third_task_fails.snap | 4 +- .../after_registering_the_3_tasks.snap | 4 +- .../only_first_task_succeed.snap | 4 +- .../second_and_third_tasks_fails.snap | 4 +- .../after_registering_the_6_tasks.snap | 4 +- .../all_other_tasks_succeeds.snap | 4 +- .../first_task_fails.snap | 4 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 4 +- .../after_registering_the_6_tasks.snap | 4 +- .../all_other_tasks_succeeds.snap | 4 +- .../first_task_succeed.snap | 4 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 4 +- .../lib.rs/test_document_replace/1.snap | 4 +- .../lib.rs/test_document_replace/2.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../five_tasks_processed.snap | 4 +- .../lib.rs/test_document_update/1.snap | 4 +- .../lib.rs/test_document_update/2.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../five_tasks_processed.snap | 4 +- .../after_registering_the_10_tasks.snap | 4 +- .../all_tasks_processed.snap | 4 +- .../five_tasks_processed.snap | 4 +- .../after_registering_settings_task.snap | 4 +- .../settings_update_processed.snap | 4 +- .../registered_a_task.snap | 4 +- crates/index-scheduler/src/utils.rs | 3 + 180 files changed, 524 insertions(+), 644 deletions(-) create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index 0130e9bfe..40526622c 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -667,7 +667,11 @@ impl IndexScheduler { /// list is updated accordingly, with the exception of the its date fields /// [`finished_at`](meilisearch_types::tasks::Task::finished_at) and [`started_at`](meilisearch_types::tasks::Task::started_at). #[tracing::instrument(level = "trace", skip(self, batch), target = "indexing::scheduler", fields(batch=batch.to_string()))] - pub(crate) fn process_batch(&self, batch: Batch) -> Result> { + pub(crate) fn process_batch( + &self, + batch: Batch, + current_batch: &mut ProcessingBatch, + ) -> Result> { #[cfg(test)] { self.maybe_fail(crate::tests::FailureLocation::InsideProcessBatch)?; @@ -685,47 +689,25 @@ impl IndexScheduler { unreachable!() }; - let mut wtxn = self.env.write_txn()?; - let canceled_tasks_content_uuids = self.cancel_matched_tasks( - &mut wtxn, - task.uid, - matched_tasks, - previous_started_at, - &previous_processing_tasks, - )?; + let rtxn = self.env.read_txn()?; + let mut canceled_tasks = + self.cancel_matched_tasks(&rtxn, task.uid, current_batch, matched_tasks)?; task.status = Status::Succeeded; match &mut task.details { Some(Details::TaskCancelation { matched_tasks: _, - canceled_tasks, + canceled_tasks: canceled_tasks_details, original_filter: _, }) => { - *canceled_tasks = Some(canceled_tasks_content_uuids.len() as u64); + *canceled_tasks_details = Some(canceled_tasks.len() as u64); } _ => unreachable!(), } - // We must only remove the content files if the transaction is successfully committed - // and if errors occurs when we are deleting files we must do our best to delete - // everything. We do not return the encountered errors when deleting the content - // files as it is not a breaking operation and we can safely continue our job. - match wtxn.commit() { - Ok(()) => { - for content_uuid in canceled_tasks_content_uuids { - if let Err(error) = self.delete_update_file(content_uuid) { - tracing::error!( - file_content_uuid = %content_uuid, - %error, - "Failed deleting content file" - ) - } - } - } - Err(e) => return Err(e.into()), - } + canceled_tasks.push(task); - Ok(vec![task]) + Ok(canceled_tasks) } Batch::TaskDeletions(mut tasks) => { // 1. Retrieve the tasks that matched the query at enqueue-time. @@ -1090,7 +1072,10 @@ impl IndexScheduler { } self.index_mapper.create_index(wtxn, &index_uid, None)?; - self.process_batch(Batch::IndexUpdate { index_uid, primary_key, task }) + self.process_batch( + Batch::IndexUpdate { index_uid, primary_key, task }, + current_batch, + ) } Batch::IndexUpdate { index_uid, primary_key, mut task } => { let rtxn = self.env.read_txn()?; @@ -1744,41 +1729,31 @@ impl IndexScheduler { /// Cancel each given task from all the databases (if it is cancelable). /// - /// Returns the content files that the transaction owner must delete if the commit is successful. + /// Returns the list of tasks that matched the filter and must be written in the database. fn cancel_matched_tasks( &self, - wtxn: &mut RwTxn, + rtxn: &RoTxn, cancel_task_id: TaskId, + current_batch: &mut ProcessingBatch, matched_tasks: &RoaringBitmap, - previous_started_at: OffsetDateTime, - previous_processing_tasks: &RoaringBitmap, - ) -> Result> { - let now = OffsetDateTime::now_utc(); - + ) -> Result> { // 1. Remove from this list the tasks that we are not allowed to cancel // Notice that only the _enqueued_ ones are cancelable and we should // have already aborted the indexation of the _processing_ ones - let cancelable_tasks = self.get_status(wtxn, Status::Enqueued)?; + let cancelable_tasks = self.get_status(rtxn, Status::Enqueued)?; let tasks_to_cancel = cancelable_tasks & matched_tasks; // 2. We now have a list of tasks to cancel, cancel them - let mut content_files_to_delete = Vec::new(); - for mut task in self.get_existing_tasks(wtxn, tasks_to_cancel.iter())? { - if let Some(uuid) = task.content_uuid() { - content_files_to_delete.push(uuid); - } - if previous_processing_tasks.contains(task.uid) { - task.started_at = Some(previous_started_at); - } + let mut tasks = self.get_existing_tasks(rtxn, tasks_to_cancel.iter())?; + + for task in tasks.iter_mut() { task.status = Status::Canceled; task.canceled_by = Some(cancel_task_id); - task.finished_at = Some(now); - task.details = task.details.map(|d| d.to_failed()); - self.update_task(wtxn, &task)?; + task.details = task.details.as_ref().map(|d| d.to_failed()); + current_batch.processing(Some(task)); } - self.canceled_by.put(wtxn, &cancel_task_id, &tasks_to_cancel)?; - Ok(content_files_to_delete) + Ok(tasks) } } diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index da0d90baa..af56fe467 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -40,7 +40,6 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { batch_status, batch_kind, batch_index_tasks, - batch_canceled_by, batch_enqueued_at, batch_started_at, batch_finished_at, @@ -131,10 +130,6 @@ pub fn snapshot_index_scheduler(scheduler: &IndexScheduler) -> String { snap.push_str(&snapshot_index_tasks(&rtxn, *batch_index_tasks)); snap.push_str("----------------------------------------------------------------------\n"); - snap.push_str("### Batches Canceled By:\n"); - snap.push_str(&snapshot_canceled_by(&rtxn, *batch_canceled_by)); - snap.push_str("\n----------------------------------------------------------------------\n"); - snap.push_str("### Batches Enqueued At:\n"); snap.push_str(&snapshot_date_db(&rtxn, *batch_enqueued_at)); snap.push_str("----------------------------------------------------------------------\n"); diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 5ba93f020..7ee799bd4 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -228,7 +228,6 @@ mod db_name { pub const BATCH_STATUS: &str = "batch-status"; pub const BATCH_KIND: &str = "batch-kind"; pub const BATCH_INDEX_TASKS: &str = "batch-index-tasks"; - pub const BATCH_CANCELED_BY: &str = "batch-canceled_by"; pub const BATCH_ENQUEUED_AT: &str = "batch-enqueued-at"; pub const BATCH_STARTED_AT: &str = "batch-started-at"; pub const BATCH_FINISHED_AT: &str = "batch-finished-at"; @@ -344,8 +343,6 @@ pub struct IndexScheduler { pub(crate) batch_kind: Database, RoaringBitmapCodec>, /// Store the batches associated to an index. pub(crate) batch_index_tasks: Database, - /// Store the batches containing a task canceled by a task uid - pub(crate) batch_canceled_by: Database, /// Store the batches containing tasks which were enqueued at a specific date pub(crate) batch_enqueued_at: Database, /// Store the batches containing finished tasks started at a specific date @@ -437,7 +434,6 @@ impl IndexScheduler { batch_status: self.batch_status, batch_kind: self.batch_kind, batch_index_tasks: self.batch_index_tasks, - batch_canceled_by: self.batch_canceled_by, batch_enqueued_at: self.batch_enqueued_at, batch_started_at: self.batch_started_at, batch_finished_at: self.batch_finished_at, @@ -501,7 +497,7 @@ impl IndexScheduler { let env = unsafe { heed::EnvOpenOptions::new() - .max_dbs(20) + .max_dbs(19) .map_size(budget.task_db_size) .open(options.tasks_path) }?; @@ -527,7 +523,6 @@ impl IndexScheduler { let batch_status = env.create_database(&mut wtxn, Some(db_name::BATCH_STATUS))?; let batch_kind = env.create_database(&mut wtxn, Some(db_name::BATCH_KIND))?; let batch_index_tasks = env.create_database(&mut wtxn, Some(db_name::BATCH_INDEX_TASKS))?; - let batch_canceled_by = env.create_database(&mut wtxn, Some(db_name::BATCH_CANCELED_BY))?; let batch_enqueued_at = env.create_database(&mut wtxn, Some(db_name::BATCH_ENQUEUED_AT))?; let batch_started_at = env.create_database(&mut wtxn, Some(db_name::BATCH_STARTED_AT))?; let batch_finished_at = env.create_database(&mut wtxn, Some(db_name::BATCH_FINISHED_AT))?; @@ -554,7 +549,6 @@ impl IndexScheduler { batch_status, batch_kind, batch_index_tasks, - batch_canceled_by, batch_enqueued_at, batch_started_at, batch_finished_at, @@ -1003,16 +997,23 @@ impl IndexScheduler { batches &= batches_by_task_uids; } + // There is no database for this query, we must retrieve the task queried by the client and ensure it's valid if let Some(canceled_by) = &query.canceled_by { let mut all_canceled_batches = RoaringBitmap::new(); for cancel_uid in canceled_by { - if let Some(canceled_by_uid) = self.batch_canceled_by.get(rtxn, cancel_uid)? { - all_canceled_batches |= canceled_by_uid; + if let Some(task) = self.get_task(rtxn, *cancel_uid)? { + if task.kind.as_kind() == Kind::TaskCancelation + && task.status == Status::Succeeded + { + if let Some(batch_uid) = task.batch_uid { + all_canceled_batches.insert(batch_uid); + } + } } } // if the canceled_by has been specified but no batch - // matches then we prefer matching zero than all tasks. + // matches then we prefer matching zero than all batches. if all_canceled_batches.is_empty() { return Ok(RoaringBitmap::new()); } else { @@ -1266,24 +1267,35 @@ impl IndexScheduler { } } - // Any task that is internally associated with a non-authorized index - // must be discarded. - // This works because currently batches cannot contains tasks from multiple indexes at the same time. + // Any batch that is internally associated with at least one authorized index + // must be returned. if !filters.all_indexes_authorized() { + let mut valid_indexes = RoaringBitmap::new(); + let mut forbidden_indexes = RoaringBitmap::new(); + let all_indexes_iter = self.batch_index_tasks.iter(rtxn)?; for result in all_indexes_iter { let (index, index_tasks) = result?; - if !filters.is_index_authorized(index) { - batches -= index_tasks; + if filters.is_index_authorized(index) { + valid_indexes |= index_tasks; + } else { + forbidden_indexes |= index_tasks; } } if let Some(batch) = processing.batch.as_ref() { for index in &batch.indexes { - if !filters.is_index_authorized(index) { - batches.remove(batch.uid); + if filters.is_index_authorized(index) { + valid_indexes.insert(batch.uid); + } else { + forbidden_indexes.insert(batch.uid); } } } + + // If a batch had ONE valid task then it should be returned + let invalid_batches = forbidden_indexes - valid_indexes; + + batches -= invalid_batches; } Ok((batches, total_batches.len())) @@ -1559,11 +1571,16 @@ impl IndexScheduler { // 2. Process the tasks let res = { let cloned_index_scheduler = self.private_clone(); - let handle = std::thread::Builder::new() - .name(String::from("batch-operation")) - .spawn(move || cloned_index_scheduler.process_batch(batch)) - .unwrap(); - handle.join().unwrap_or(Err(Error::ProcessBatchPanicked)) + let processing_batch = &mut processing_batch; + std::thread::scope(|s| { + let handle = std::thread::Builder::new() + .name(String::from("batch-operation")) + .spawn_scoped(s, move || { + cloned_index_scheduler.process_batch(batch, processing_batch) + }) + .unwrap(); + handle.join().unwrap_or(Err(Error::ProcessBatchPanicked)) + }) }; // Reset the currently updating index to relinquish the index handle @@ -1582,11 +1599,20 @@ impl IndexScheduler { let mut success = 0; let mut failure = 0; + let mut canceled_by = None; + let mut canceled = RoaringBitmap::new(); + + dbg!(&tasks); #[allow(unused_variables)] for (i, mut task) in tasks.into_iter().enumerate() { - task.started_at = Some(processing_batch.started_at); - task.finished_at = Some(finished_at); + if task.status != Status::Canceled { + task.started_at = Some(processing_batch.started_at); + task.finished_at = Some(finished_at); + } else { + canceled.insert(task.uid); + canceled_by = task.canceled_by; + } #[cfg(test)] self.maybe_fail( @@ -1604,6 +1630,10 @@ impl IndexScheduler { .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; processing_batch.update(&task); } + if let Some(canceled_by) = canceled_by { + println!("inserting the canceled by {canceled_by}: {canceled:?}"); + self.canceled_by.put(&mut wtxn, &canceled_by, &canceled)?; + } tracing::info!("A batch of tasks was successfully completed with {success} successful tasks and {failure} failed tasks."); } // If we have an abortion error we must stop the tick here and re-schedule tasks. @@ -4136,6 +4166,7 @@ mod tests { tasks: [0, 1, 2, 3].into_iter().collect(), }; let task_cancelation = index_scheduler.register(kind, None, false).unwrap(); + println!("HEEERE"); handle.advance_n_successful_batches(1); snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); @@ -4577,13 +4608,12 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) .unwrap(); - // 0 is not returned because it was not canceled, 3 is not returned because it is the uid of the - // taskCancelation itself - snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); + // The batch zero was the index creation task, the 1 is the task cancellation + snapshot!(snapshot_bitmap(&batches), @"[1,]"); let query = Query { canceled_by: Some(vec![task_cancelation.uid]), ..Query::default() }; let (batches, _) = index_scheduler - .get_task_ids_from_authorized_indexes( + .get_batch_ids_from_authorized_indexes( &rtxn, &query, &AuthFilter::with_allowed_indexes( @@ -5885,7 +5915,7 @@ mod tests { let kind = KindWithContent::IndexCreation { index_uid: S("doggo"), primary_key: None }; let task = index_scheduler.register(kind, None, true).unwrap(); snapshot!(task.uid, @"0"); - snapshot!(snapshot_index_scheduler(&index_scheduler), @r###" + snapshot!(snapshot_index_scheduler(&index_scheduler), @r" ### Autobatching Enabled = true ### Processing batch None: [] @@ -5919,9 +5949,6 @@ mod tests { ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: - ---------------------------------------------------------------------- - ### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- @@ -5932,12 +5959,12 @@ mod tests { ### File Store: ---------------------------------------------------------------------- - "###); + "); let kind = KindWithContent::IndexCreation { index_uid: S("doggo"), primary_key: None }; let task = index_scheduler.register(kind, Some(12), true).unwrap(); snapshot!(task.uid, @"12"); - snapshot!(snapshot_index_scheduler(&index_scheduler), @r###" + snapshot!(snapshot_index_scheduler(&index_scheduler), @r" ### Autobatching Enabled = true ### Processing batch None: [] @@ -5971,9 +5998,6 @@ mod tests { ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: - ---------------------------------------------------------------------- - ### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- @@ -5984,7 +6008,7 @@ mod tests { ### File Store: ---------------------------------------------------------------------- - "###); + "); } #[test] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap index 077784965..d19ea3960 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap @@ -1,13 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: canceled, canceled_by: 1, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(1), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} +0 {uid: 0, batch_uid: 0, status: canceled, canceled_by: 1, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(1), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -36,10 +37,35 @@ catto [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [1,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"taskCancelation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: +00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap index d1938e82d..b895bbc7c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/initial_tasks_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap index 1784652c2..55b4275c7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(1): @@ -58,9 +59,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap index 1e5182f80..4989ef2ff 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap @@ -1,15 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: canceled, canceled_by: 3, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "beavero", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} -2 {uid: 2, status: canceled, canceled_by: 3, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "wolfo", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} -3 {uid: 3, status: succeeded, details: { matched_tasks: 3, canceled_tasks: Some(2), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { received_documents: 1, indexed_documents: Some(1) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 1, status: canceled, canceled_by: 3, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "beavero", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000001, documents_count: 1, allow_index_creation: true }} +2 {uid: 2, batch_uid: 1, status: canceled, canceled_by: 3, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "wolfo", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000002, documents_count: 1, allow_index_creation: true }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { matched_tasks: 3, canceled_tasks: Some(2), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -42,15 +43,47 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ---------------------------------------------------------------------- ### Started At: [timestamp] [0,] -[timestamp] [1,] [timestamp] [3,] ---------------------------------------------------------------------- ### Finished At: [timestamp] [0,] -[timestamp] [1,2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [3,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,1,] +"taskCancelation" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +beavero [1,] +catto [0,] +wolfo [1,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: +00000000-0000-0000-0000-000000000001 +00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap index d3671cb4d..524f865d8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -54,9 +55,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap index 92e484c93..c67c45f02 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(1): @@ -57,9 +58,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap index 8c6b6be65..8821af805 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/after_dump_register.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -38,9 +39,6 @@ enqueued [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap index f3d7b363f..b619399bf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap @@ -1,13 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: canceled, canceled_by: 1, details: { dump_uid: None }, kind: DumpCreation { keys: [], instance_uid: None }} -1 {uid: 1, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(0), original_filter: "cancel dump" }, kind: TaskCancelation { query: "cancel dump", tasks: RoaringBitmap<[0]> }} +0 {uid: 0, batch_uid: 0, status: canceled, canceled_by: 1, details: { dump_uid: None }, kind: DumpCreation { keys: [], instance_uid: None }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(1), original_filter: "cancel dump" }, kind: TaskCancelation { query: "cancel dump", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -32,14 +33,36 @@ canceled [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Started At: -[timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [1,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"taskCancelation" [0,] +"dumpCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap index 7406a373b..f4b6c31a1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_registered.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -41,9 +42,6 @@ enqueued [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap index 38925a23d..527908093 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/aborted_indexation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -43,9 +44,6 @@ catto: { number_of_documents: 0, field_distribution: {} } ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap index 0ede1ffd3..c8f661fb0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap @@ -1,13 +1,14 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: canceled, canceled_by: 1, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} -1 {uid: 1, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(1), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} +0 {uid: 0, batch_uid: 0, status: canceled, canceled_by: 1, details: { received_documents: 1, indexed_documents: Some(0) }, kind: DocumentAdditionOrUpdate { index_uid: "catto", primary_key: None, method: ReplaceDocuments, content_file: 00000000-0000-0000-0000-000000000000, documents_count: 1, allow_index_creation: true }} +1 {uid: 1, batch_uid: 0, status: succeeded, details: { matched_tasks: 1, canceled_tasks: Some(1), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -34,14 +35,38 @@ catto: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### Started At: -[timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [0,] [timestamp] [1,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [1,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"documentAdditionOrUpdate" [0,] +"taskCancelation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- ### File Store: +00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap index 3b8a9a623..0f5795f35 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_task_registered.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -42,9 +43,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap index 5c1c3a765..7646df5ad 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/initial_task_processing.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -39,9 +40,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap index 6b6af0667..087257e18 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap index 6c8ead6b4..94465298d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -25,7 +26,6 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ---------------------------------------------------------------------- ### Canceled By: -1 [] ---------------------------------------------------------------------- ### Enqueued At: @@ -57,9 +57,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap index ab62eb146..8cddcf06d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap index 6b6af0667..087257e18 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap index 3b4d6db02..b024305dd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -86,9 +87,6 @@ succeeded [0,1,2,3,4,5,] cattos [1,4,] doggos [0,3,] girafos [2,5,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap index 07ab97def..d8a689669 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_register.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap index 03484afe0..a023166ca 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/after_the_batch_creation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap index c194af741..52fefbbec 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap index 668f9d5bf..73f2730d2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -52,9 +53,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap index a26cb23aa..b1337b287 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap index 9765289fb..60e2d22be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap index f8642736c..66d073dc0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -54,9 +55,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap index deafc4c81..648c66927 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -59,9 +60,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap index 198956185..230b5e195 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap index 4e9b84e52..9b22afff0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap index 84e037b05..914660746 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ doggos [0,1,2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap index 8f2bed791..c252d35c9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/1.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap index ade21179b..91b1ebd93 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -51,9 +52,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 9a7b4686c..1ea3bdbd4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -50,9 +51,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index 60f71df9e..f3d7e2379 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap index acfdb5e51..2e96a4614 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap index 9748964e3..d4f8b47b9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap index 03484afe0..a023166ca 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_batch_created.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index 19881a91c..f79a7fed1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -47,9 +48,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap index 07ab97def..d8a689669 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap index 74e001fba..37ef7a5cb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -56,9 +57,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap index 19d7a0c0a..dbe571e1b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -51,9 +52,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index a6a036eee..762173c27 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -63,7 +64,6 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] -failed [2,] ---------------------------------------------------------------------- ### Batches Kind: "documentAdditionOrUpdate" [1,] @@ -72,9 +72,6 @@ failed [2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap index 093e693d1..424218e1c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -65,9 +66,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap index f6ff0721e..9e1995fee 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_setting_and_document_addition.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap index 03d239939..5129662eb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/after_register.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 154b1f35b..34f6ad7fd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -47,9 +48,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap index 177307427..33ddc49e8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_batch_succeeded.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -40,9 +41,6 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap index 177307427..33ddc49e8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/after_failing_to_commit.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -40,9 +41,6 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap index 07ab97def..d8a689669 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/document_addition_succeeded_but_index_scheduler_not_updated.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap index 07ab97def..d8a689669 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap index c194af741..52fefbbec 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap index e2cdc8d46..cc392afbb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -62,9 +63,6 @@ succeeded [0,1,2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap index 859e3b95d..1e4534935 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap index 44b25b149..41e464287 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -56,9 +57,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap index 4eefe83c2..03c7b3a5a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -51,9 +52,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap index 96d060a92..f9e6df03e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after_registering_settings_task_vectors.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap index 044791d61..7bdb75143 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap index eabfaed29..98ab857a9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/after_batch_creation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -39,9 +40,6 @@ index_a [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap index 05bad8454..e3627bbd3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ index_a [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap index bf009e414..e23aa11e1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -42,9 +43,6 @@ index_b [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap index 9c86652db..60104b505 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/insert_task_while_another_task_is_processing/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -45,9 +46,6 @@ index_b [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index 17ed67aaf..fdd8e1f1d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -47,9 +48,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap index 03d239939..5129662eb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ catto [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap index 31fb88530..6bc6f22fd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -54,9 +55,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap index 7bafb0848..747d64903 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -60,9 +61,6 @@ succeeded [0,1,] ### Batches Index Tasks: cattos [1,] doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap index b2967a78e..b6c419847 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -64,9 +65,6 @@ succeeded [0,1,2,] ### Batches Index Tasks: cattos [1,] doggos [0,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap index 198956185..230b5e195 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap index 5460e7476..a0148db63 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap index 610282102..bee90a73b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ doggos [0,2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap index 915a39cb0..b5894122f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -55,9 +56,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap index dfe92d4b3..93fc7c824 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -68,9 +69,6 @@ succeeded [0,1,2,3,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap index d92fa144c..33cea7854 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap index c75e0c550..ebd130966 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_fourth_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -46,9 +47,6 @@ doggos [0,1,2,3,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap index 87f7406dd..c53aec0c9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -42,9 +43,6 @@ doggos [0,1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap index 86cb34f85..7679999ce 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -44,9 +45,6 @@ doggos [0,1,2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap index 597e6704d..fa00c237b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -60,9 +61,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap index 85cf963be..f9c3166ad 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -64,9 +65,6 @@ succeeded [0,1,2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap new file mode 100644 index 000000000..3af67a73c --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap @@ -0,0 +1,86 @@ +--- +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text +--- +### Autobatching Enabled = true +### Processing batch None: +[] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, batch_uid: 1, status: canceled, canceled_by: 3, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, batch_uid: 1, status: canceled, canceled_by: 3, details: { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { matched_tasks: 3, canceled_tasks: Some(2), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} +---------------------------------------------------------------------- +### Status: +enqueued [] +succeeded [0,3,] +canceled [1,2,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,] +"indexSwap" [2,] +"taskCancelation" [3,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,2,] +doggo [1,2,] +---------------------------------------------------------------------- +### Index Mapper: +catto: { number_of_documents: 0, field_distribution: {} } + +---------------------------------------------------------------------- +### Canceled By: +3 [1,2,] + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Started At: +[timestamp] [0,] +[timestamp] [3,] +---------------------------------------------------------------------- +### Finished At: +[timestamp] [0,] +[timestamp] [3,] +---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [3,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +"indexSwap" [1,] +"taskCancelation" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,1,] +doggo [1,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap index d22441b0b..cb12fa554 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -66,9 +67,6 @@ succeeded [0,1,2,] catto [2,] doggo [0,] whalo [1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap index c6bf88bb0..64503a754 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggo [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap index cae2c4806..171f6dab4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ whalo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap index 2346e5e68..f811b99a6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ whalo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap index b87a06b2b..7325520eb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -67,9 +68,6 @@ failed [2,] catto [0,] doggo [1,] whalo [2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap index 7428155e9..78a6c4228 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/start.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ whalo [2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap index 625017e91..2bf1b4509 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -75,9 +76,6 @@ failed [2,3,] catto [0,2,3,] doggo [1,2,] whalo [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap index f5a544f18..30f62c526 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/start.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ whalo [3,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap index b05f05d5d..3af67a73c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap @@ -1,15 +1,16 @@ --- -source: index-scheduler/src/lib.rs +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true -### Processing Tasks: +### Processing batch None: [] ---------------------------------------------------------------------- ### All Tasks: -0 {uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} -1 {uid: 1, status: canceled, canceled_by: 3, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} -2 {uid: 2, status: canceled, canceled_by: 3, details: { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }} -3 {uid: 3, status: succeeded, details: { matched_tasks: 3, canceled_tasks: Some(0), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, batch_uid: 1, status: canceled, canceled_by: 3, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, batch_uid: 1, status: canceled, canceled_by: 3, details: { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }, kind: IndexSwap { swaps: [IndexSwap { indexes: ("catto", "doggo") }] }} +3 {uid: 3, batch_uid: 1, status: succeeded, details: { matched_tasks: 3, canceled_tasks: Some(2), original_filter: "test_query" }, kind: TaskCancelation { query: "test_query", tasks: RoaringBitmap<[0, 1, 2]> }} ---------------------------------------------------------------------- ### Status: enqueued [] @@ -45,10 +46,41 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Finished At: [timestamp] [0,] -[timestamp] [1,2,] [timestamp] [3,] ---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, } +1 {uid: 1, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +1 [3,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,1,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,1,] +"indexSwap" [1,] +"taskCancelation" [1,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,1,] +doggo [1,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +[timestamp] [1,] +---------------------------------------------------------------------- ### File Store: ---------------------------------------------------------------------- - diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap index d22441b0b..cb12fa554 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -66,9 +67,6 @@ succeeded [0,1,2,] catto [2,] doggo [0,] whalo [1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap index c6bf88bb0..64503a754 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggo [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap index cae2c4806..171f6dab4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_second_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ whalo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap index 2346e5e68..f811b99a6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/registered_the_third_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ whalo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index b87a06b2b..7325520eb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -67,9 +68,6 @@ failed [2,] catto [0,] doggo [1,] whalo [2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap index 7428155e9..78a6c4228 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/start.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ whalo [2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap index f5a544f18..30f62c526 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_special_rules/start.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ whalo [3,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap index 62a7ae13a..8341d947d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/register/everything_is_successfully_registered.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -47,9 +48,6 @@ doggo [3,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap index 91c15c3ee..639972a3e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: a [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap index 63e254e35..4b94276ab 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -63,9 +64,6 @@ succeeded [0,1,] ### Batches Index Tasks: a [0,] b [1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap index 529fa818e..4ab09f46c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -69,9 +70,6 @@ succeeded [0,1,2,] a [0,] b [1,] c [2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap index 9f47fbebd..41d8bec15 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -75,9 +76,6 @@ a [0,] b [1,] c [2,] d [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap index 74bf714b1..108a28b11 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -85,9 +86,6 @@ a [0,4,] b [1,4,] c [2,4,] d [3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap index 23cb14ac1..02b746053 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -78,9 +79,6 @@ a [0,] b [1,] c [2,] d [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap index a279d967f..0209f57bc 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -89,9 +90,6 @@ a [0,4,5,] b [1,4,] c [2,4,5,] d [3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap index e3be49476..bb165d824 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -95,9 +96,6 @@ a [0,4,5,] b [1,4,] c [2,4,5,] d [3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap index 2014150bb..063b97d62 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -80,9 +81,6 @@ a [0,] b [1,] c [2,] d [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap index 9f47fbebd..41d8bec15 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -75,9 +76,6 @@ a [0,] b [1,] c [2,] d [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index df676be58..3bf223e41 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -89,9 +90,6 @@ c [2,4,] d [3,4,] e [4,] f [4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap index 9f47fbebd..41d8bec15 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -75,9 +76,6 @@ a [0,] b [1,] c [2,] d [3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap index 88e7db81c..0d51e242c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap index 50d9a972a..e88870283 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -51,9 +52,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 72dc1bfae..9736e07a7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -56,9 +57,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap index 42d528498..7dac66431 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -54,9 +55,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap index 88e7db81c..0d51e242c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -42,9 +43,6 @@ doggo [1,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap index 50d9a972a..e88870283 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -51,9 +52,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index 71e834518..6985fe1e5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -54,9 +55,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: catto [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap index 4be93852c..aed0a818a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/initial_tasks_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -45,9 +46,6 @@ doggo [2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap index 834dd2e74..3fd3ca34b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -55,9 +56,6 @@ succeeded [0,] "taskDeletion" [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap index f5d93baa3..746caa1de 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_enqueued.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ doggo [2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap index d9e7733d4..e72e255e7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_processing.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch Some(0): @@ -48,9 +49,6 @@ doggo [2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap index 10149200c..8ca3aab2b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -74,9 +75,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap index fdbef5f31..b6a0c00c9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -69,9 +70,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap index 0260edea5..1f77245be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap index 198956185..230b5e195 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap index 6e4179250..abc31b0cd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -69,9 +70,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap index c66a50d47..cc716cfc8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -110,9 +111,6 @@ succeeded [0,1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,6,7,8,9,10,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap index 8440c7113..c68517991 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -90,9 +91,6 @@ succeeded [0,1,2,3,4,5,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap index 45eb1b027..f4c3cdc65 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap index d92fa144c..33cea7854 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index 9600955a0..fe329cb55 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -65,9 +66,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap index 06cc66a60..8b463b588 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap index 74111aac3..537980795 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index 2fe601741..b3f8a48a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -101,9 +102,6 @@ failed [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,6,7,8,9,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index bc6fecb2a..468eac198 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -81,9 +82,6 @@ failed [0,1,2,3,4,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap index 8ee0a9b12..3cdee6f23 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index 0e225ea8d..92682a4e2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -72,9 +73,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index ac3c29fcb..87d14ae51 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -65,9 +66,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap index 1a0f4a54d..c61ba5983 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -69,9 +70,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap index feec34884..723a387cd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -74,9 +75,6 @@ succeeded [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap index 0260edea5..1f77245be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap index 198956185..230b5e195 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/registered_the_first_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap index f0f74b328..e8ee841ae 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/after_registering_the_5_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -47,9 +48,6 @@ doggos [0,1,2,3,4,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index 953297977..f3ee85d54 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -70,9 +71,6 @@ failed [0,2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index 502fefbfd..ded62c6e1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -56,9 +57,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 95c76085b..0d4ea85be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -66,9 +67,6 @@ failed [0,2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index e29c5e90c..91ad54ff1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -62,9 +63,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap index 3ea317c43..a3a481855 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/after_registering_the_3_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -43,9 +44,6 @@ doggos [0,1,2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap index 651b3cf5b..d43603f3b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -52,9 +53,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index 6fca659b1..913c3e1d9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ failed [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index 18baf7207..5d0251da3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -62,9 +63,6 @@ failed [1,2,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap index 9df0f214d..3eb5c7a4d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/after_registering_the_3_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -43,9 +44,6 @@ doggos [0,1,2,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap index cfe528340..a6d327add 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -52,9 +53,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 7ed185b9b..4d7af4a8d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ failed [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap index 1e6cff26c..3306009aa 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/after_registering_the_6_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -49,9 +50,6 @@ doggos [0,1,2,3,4,5,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index 577938932..1fcaefeed 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -72,9 +73,6 @@ failed [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index e807035a9..e13c0f6ab 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ failed [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index 9e718473f..a76a5983e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -62,9 +63,6 @@ failed [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index ec4449e29..507ebe04d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -68,9 +69,6 @@ failed [0,1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap index de01fce5a..2876c7681 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/after_registering_the_6_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -49,9 +50,6 @@ doggos [0,1,2,3,4,5,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index b4d54f680..90807eeb8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -72,9 +73,6 @@ failed [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap index 8f4ceb94e..bdfc30547 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -58,9 +59,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index 350ace217..5c34f53c0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -64,9 +65,6 @@ failed [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index f908e7a8c..3c18f87b2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -68,9 +69,6 @@ failed [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap index 355ef8821..a5fbc024c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/1.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap index c3ff75f58..916f0ae0f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -66,9 +67,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap index 88d9addb8..ba16d64f1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap index 40b51ed14..0ea35496e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -102,9 +103,6 @@ succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,6,7,8,9,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap index 62ea510d1..140f540c6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -82,9 +83,6 @@ succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap index 7aeb7da17..5444d0a3e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/1.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap index a922b0595..502493423 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -66,9 +67,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap index fea75fb83..35368e4b3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap index 2f8a5e4d8..924033507 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -102,9 +103,6 @@ succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,6,7,8,9,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap index ca1f46581..c762ac7f0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = false ### Processing batch None: @@ -82,9 +83,6 @@ succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap index 6575b835d..773f43c2c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/after_registering_the_10_tasks.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -57,9 +58,6 @@ doggos [0,1,2,3,4,5,6,7,8,9,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap index 453ff8c61..392ea405a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -102,9 +103,6 @@ succeeded [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,5,6,7,8,9,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap index 1e06b6dce..cd08d9289 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -82,9 +83,6 @@ succeeded [0,1,2,3,4,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,1,2,3,4,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap index dd81f33e7..22900371e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/after_registering_settings_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ doggos [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap index d889e5706..a5b4849a9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -48,9 +49,6 @@ succeeded [0,] ---------------------------------------------------------------------- ### Batches Index Tasks: doggos [0,] ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap index 05bad8454..e3627bbd3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_task_is_processing/registered_a_task.snap @@ -1,5 +1,6 @@ --- source: crates/index-scheduler/src/lib.rs +snapshot_kind: text --- ### Autobatching Enabled = true ### Processing batch None: @@ -39,9 +40,6 @@ index_a [0,] ### Batches Kind: ---------------------------------------------------------------------- ### Batches Index Tasks: ----------------------------------------------------------------------- -### Batches Canceled By: - ---------------------------------------------------------------------- ### Batches Enqueued At: ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 8ffef39f3..edb413600 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -138,6 +138,7 @@ impl IndexScheduler { bitmap.insert(batch.uid); })?; } + if let Some(enqueued_at) = batch.oldest_enqueued_at { insert_task_datetime(wtxn, self.batch_enqueued_at, enqueued_at, batch.uid)?; } @@ -204,6 +205,8 @@ impl IndexScheduler { pub(crate) fn update_task(&self, wtxn: &mut RwTxn, task: &Task) -> Result<()> { let old_task = self.get_task(wtxn, task.uid)?.ok_or(Error::CorruptedTaskQueue)?; + dbg!(&task); + debug_assert_eq!(old_task.uid, task.uid); debug_assert!(old_task.batch_uid.is_none() && task.batch_uid.is_some()); From 62646af7b98dc95113fb027b0f0b05a5f8d31962 Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 14:36:50 +0100 Subject: [PATCH 07/22] implements the automatic batch deletion --- crates/index-scheduler/src/batch.rs | 62 ++++++++++++++++--- .../task_deletion_processed.snap | 7 +-- .../task_deletion_processed.snap | 7 +-- 3 files changed, 59 insertions(+), 17 deletions(-) diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index 40526622c..b43efd899 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -17,13 +17,14 @@ tasks individually, but should be much faster since we are only performing one indexing operation. */ -use std::collections::{BTreeSet, HashSet}; +use std::collections::{BTreeSet, HashMap, HashSet}; use std::ffi::OsStr; use std::fmt; use std::fs::{self, File}; use std::io::BufWriter; use dump::IndexMetadata; +use meilisearch_types::batches::BatchId; use meilisearch_types::error::Code; use meilisearch_types::heed::{RoTxn, RwTxn}; use meilisearch_types::milli::documents::{obkv_to_object, DocumentsBatchReader}; @@ -1675,6 +1676,8 @@ impl IndexScheduler { let mut affected_statuses = HashSet::new(); let mut affected_kinds = HashSet::new(); let mut affected_canceled_by = RoaringBitmap::new(); + // The tasks that have been removed *per batches*. + let mut affected_batches: HashMap = HashMap::new(); for task_id in to_delete_tasks.iter() { let task = self.get_task(wtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; @@ -1696,18 +1699,21 @@ impl IndexScheduler { if let Some(canceled_by) = task.canceled_by { affected_canceled_by.insert(canceled_by); } + if let Some(batch_uid) = task.batch_uid { + affected_batches.entry(batch_uid).or_default().insert(task_id); + } } - for index in affected_indexes { - self.update_index(wtxn, &index, |bitmap| *bitmap -= &to_delete_tasks)?; + for index in affected_indexes.iter() { + self.update_index(wtxn, index, |bitmap| *bitmap -= &to_delete_tasks)?; } - for status in affected_statuses { - self.update_status(wtxn, status, |bitmap| *bitmap -= &to_delete_tasks)?; + for status in affected_statuses.iter() { + self.update_status(wtxn, *status, |bitmap| *bitmap -= &to_delete_tasks)?; } - for kind in affected_kinds { - self.update_kind(wtxn, kind, |bitmap| *bitmap -= &to_delete_tasks)?; + for kind in affected_kinds.iter() { + self.update_kind(wtxn, *kind, |bitmap| *bitmap -= &to_delete_tasks)?; } for task in to_delete_tasks.iter() { @@ -1723,6 +1729,48 @@ impl IndexScheduler { } } } + for (batch_id, to_delete_tasks) in affected_batches { + if let Some(mut tasks) = self.batch_to_tasks_mapping.get(wtxn, &batch_id)? { + tasks -= &to_delete_tasks; + // We must remove the batch entirely + if tasks.is_empty() { + self.all_batches.delete(wtxn, &batch_id)?; + self.batch_to_tasks_mapping.delete(wtxn, &batch_id)?; + } + // Anyway, we must remove the batch from all its reverse indexes. + // The only way to do that is to check + + for index in affected_indexes.iter() { + let index_tasks = self.index_tasks(wtxn, index)?; + let remaining_index_tasks = index_tasks & &tasks; + if remaining_index_tasks.is_empty() { + self.update_batch_index(wtxn, index, |bitmap| { + bitmap.remove(batch_id); + })?; + } + } + + for status in affected_statuses.iter() { + let status_tasks = self.get_status(wtxn, *status)?; + let remaining_status_tasks = status_tasks & &tasks; + if remaining_status_tasks.is_empty() { + self.update_batch_status(wtxn, *status, |bitmap| { + bitmap.remove(batch_id); + })?; + } + } + + for kind in affected_kinds.iter() { + let kind_tasks = self.get_kind(wtxn, *kind)?; + let remaining_kind_tasks = kind_tasks & &tasks; + if remaining_kind_tasks.is_empty() { + self.update_batch_kind(wtxn, *kind, |bitmap| { + bitmap.remove(batch_id); + })?; + } + } + } + } Ok(to_delete_tasks) } diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 9736e07a7..24844c3f8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -41,22 +41,19 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- ### Batch to tasks mapping: -0 [0,] 1 [2,3,] ---------------------------------------------------------------------- ### Batches Status: -succeeded [0,1,] +succeeded [1,] ---------------------------------------------------------------------- ### Batches Kind: -"documentAdditionOrUpdate" [0,] +"documentAdditionOrUpdate" [] "taskDeletion" [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: -catto [0,] ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index 6985fe1e5..97106df1b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -39,22 +39,19 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } 1 {uid: 1, } ---------------------------------------------------------------------- ### Batch to tasks mapping: -0 [0,] 1 [2,] ---------------------------------------------------------------------- ### Batches Status: -succeeded [0,1,] +succeeded [1,] ---------------------------------------------------------------------- ### Batches Kind: -"documentAdditionOrUpdate" [0,] +"documentAdditionOrUpdate" [] "taskDeletion" [1,] ---------------------------------------------------------------------- ### Batches Index Tasks: -catto [0,] ---------------------------------------------------------------------- ### Batches Enqueued At: [timestamp] [0,] From f1d38581e512e13edb67299e81dbf5ed547d199b Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 15:05:34 +0100 Subject: [PATCH 08/22] add the front end tests on the batches routes --- crates/meilisearch/tests/batches/errors.rs | 211 ++++++ crates/meilisearch/tests/batches/mod.rs | 778 ++++++++++++++++++++ crates/meilisearch/tests/batches/webhook.rs | 129 ++++ crates/meilisearch/tests/common/index.rs | 29 + crates/meilisearch/tests/common/server.rs | 9 + crates/meilisearch/tests/integration.rs | 1 + 6 files changed, 1157 insertions(+) create mode 100644 crates/meilisearch/tests/batches/errors.rs create mode 100644 crates/meilisearch/tests/batches/mod.rs create mode 100644 crates/meilisearch/tests/batches/webhook.rs diff --git a/crates/meilisearch/tests/batches/errors.rs b/crates/meilisearch/tests/batches/errors.rs new file mode 100644 index 000000000..11f9e9b3c --- /dev/null +++ b/crates/meilisearch/tests/batches/errors.rs @@ -0,0 +1,211 @@ +use meili_snap::*; + +use crate::common::Server; + +#[actix_rt::test] +async fn batch_bad_uids() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("uids=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `uids`: could not parse `doggo` as a positive integer", + "code": "invalid_task_uids", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_uids" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_canceled_by() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("canceledBy=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `canceledBy`: could not parse `doggo` as a positive integer", + "code": "invalid_task_canceled_by", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_canceled_by" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_types() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("types=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `types`: `doggo` is not a valid task type. Available types are `documentAdditionOrUpdate`, `documentEdition`, `documentDeletion`, `settingsUpdate`, `indexCreation`, `indexDeletion`, `indexUpdate`, `indexSwap`, `taskCancelation`, `taskDeletion`, `dumpCreation`, `snapshotCreation`.", + "code": "invalid_task_types", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_types" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_statuses() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("statuses=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `statuses`: `doggo` is not a valid task status. Available statuses are `enqueued`, `processing`, `succeeded`, `failed`, `canceled`.", + "code": "invalid_task_statuses", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_statuses" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_index_uids() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("indexUids=the%20good%20doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r###" + { + "message": "Invalid value in parameter `indexUids`: `the good doggo` is not a valid index uid. Index uid can be an integer or a string containing only alphanumeric characters, hyphens (-) and underscores (_), and can not be more than 512 bytes.", + "code": "invalid_index_uid", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_index_uid" + } + "###); +} + +#[actix_rt::test] +async fn batch_bad_limit() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("limit=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `limit`: could not parse `doggo` as a positive integer", + "code": "invalid_task_limit", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_limit" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_from() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("from=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `from`: could not parse `doggo` as a positive integer", + "code": "invalid_task_from", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_from" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_after_enqueued_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("afterEnqueuedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `afterEnqueuedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_after_enqueued_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_after_enqueued_at" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_before_enqueued_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("beforeEnqueuedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `beforeEnqueuedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_before_enqueued_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_before_enqueued_at" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_after_started_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("afterStartedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `afterStartedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_after_started_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_after_started_at" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_before_started_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("beforeStartedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `beforeStartedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_before_started_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_before_started_at" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_after_finished_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("afterFinishedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `afterFinishedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_after_finished_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_after_finished_at" + } + "#); +} + +#[actix_rt::test] +async fn batch_bad_before_finished_at() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("beforeFinishedAt=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(json_string!(response), @r#" + { + "message": "Invalid value in parameter `beforeFinishedAt`: `doggo` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_before_finished_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_before_finished_at" + } + "#); +} diff --git a/crates/meilisearch/tests/batches/mod.rs b/crates/meilisearch/tests/batches/mod.rs new file mode 100644 index 000000000..48fbc34e3 --- /dev/null +++ b/crates/meilisearch/tests/batches/mod.rs @@ -0,0 +1,778 @@ +mod errors; + +use meili_snap::insta::assert_json_snapshot; +use meili_snap::snapshot; +use time::format_description::well_known::Rfc3339; +use time::OffsetDateTime; + +use crate::common::Server; +use crate::json; + +#[actix_rt::test] +async fn error_get_unexisting_batch_status() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + let (response, code) = index.get_batch(1).await; + + let expected_response = json!({ + "message": "batch `1` not found.", + "code": "batch_not_found", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#batch_not_found" + }); + + assert_eq!(response, expected_response); + assert_eq!(code, 404); +} + +#[actix_rt::test] +async fn get_batch_status() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index + .add_documents( + json!([{ + "id": 1, + "content": "foobar", + }]), + None, + ) + .await; + index.wait_task(0).await; + let (_response, code) = index.get_batch(1).await; + assert_eq!(code, 200); + // TODO check response format, as per #48 +} + +#[actix_rt::test] +async fn list_batches() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + let (response, code) = index.list_batches().await; + assert_eq!(code, 200); + assert_eq!(response["results"].as_array().unwrap().len(), 2); +} + +#[actix_rt::test] +async fn list_batches_with_star_filters() { + let server = Server::new().await; + let index = server.index("test"); + let (batch, _code) = index.create(None).await; + index.wait_task(batch.uid()).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + let (response, code) = index.service.get("/batches?indexUids=test").await; + assert_eq!(code, 200); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = index.service.get("/batches?indexUids=*").await; + assert_eq!(code, 200); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = index.service.get("/batches?indexUids=*,pasteque").await; + assert_eq!(code, 200); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = index.service.get("/batches?types=*").await; + assert_eq!(code, 200); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = + index.service.get("/batches?types=*,documentAdditionOrUpdate&statuses=*").await; + assert_eq!(code, 200, "{:?}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = index + .service + .get("/batches?types=*,documentAdditionOrUpdate&statuses=*,failed&indexUids=test") + .await; + assert_eq!(code, 200, "{:?}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); + + let (response, code) = index + .service + .get("/batches?types=*,documentAdditionOrUpdate&statuses=*,failed&indexUids=test,*") + .await; + assert_eq!(code, 200, "{:?}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); +} + +#[actix_rt::test] +async fn list_batches_status_filtered() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + + let (response, code) = index.filtered_batches(&[], &["succeeded"], &[]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 1); + + // We can't be sure that the update isn't already processed so we can't test this + // let (response, code) = index.filtered_batches(&[], &["processing"]).await; + // assert_eq!(code, 200, "{}", response); + // assert_eq!(response["results"].as_array().unwrap().len(), 1); + + index.wait_task(1).await; + + let (response, code) = index.filtered_batches(&[], &["succeeded"], &[]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); +} + +#[actix_rt::test] +async fn list_batches_type_filtered() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + + let (response, code) = index.filtered_batches(&["indexCreation"], &[], &[]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 1); + + let (response, code) = + index.filtered_batches(&["indexCreation", "documentAdditionOrUpdate"], &[], &[]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); +} + +#[actix_rt::test] +async fn list_batches_invalid_canceled_by_filter() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + + let (response, code) = index.filtered_batches(&[], &[], &["0"]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 0); +} + +#[actix_rt::test] +async fn list_batches_status_and_type_filtered() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + index + .add_documents(serde_json::from_str(include_str!("../assets/test_set.json")).unwrap(), None) + .await; + + let (response, code) = index.filtered_batches(&["indexCreation"], &["failed"], &[]).await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 0); + + let (response, code) = index + .filtered_batches( + &["indexCreation", "documentAdditionOrUpdate"], + &["succeeded", "processing", "enqueued"], + &[], + ) + .await; + assert_eq!(code, 200, "{}", response); + assert_eq!(response["results"].as_array().unwrap().len(), 2); +} + +#[actix_rt::test] +async fn get_batch_filter_error() { + let server = Server::new().await; + + let (response, code) = server.batches_filter("lol=pied").await; + assert_eq!(code, 400, "{}", response); + meili_snap::snapshot!(meili_snap::json_string!(response), @r###" + { + "message": "Unknown parameter `lol`: expected one of `limit`, `from`, `batchUids`, `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "code": "bad_request", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#bad_request" + } + "###); + + let (response, code) = server.batches_filter("uids=pied").await; + assert_eq!(code, 400, "{}", response); + meili_snap::snapshot!(meili_snap::json_string!(response), @r#" + { + "message": "Invalid value in parameter `uids`: could not parse `pied` as a positive integer", + "code": "invalid_task_uids", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_uids" + } + "#); + + let (response, code) = server.batches_filter("from=pied").await; + assert_eq!(code, 400, "{}", response); + meili_snap::snapshot!(meili_snap::json_string!(response), @r#" + { + "message": "Invalid value in parameter `from`: could not parse `pied` as a positive integer", + "code": "invalid_task_from", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_from" + } + "#); + + let (response, code) = server.batches_filter("beforeStartedAt=pied").await; + assert_eq!(code, 400, "{}", response); + meili_snap::snapshot!(meili_snap::json_string!(response), @r#" + { + "message": "Invalid value in parameter `beforeStartedAt`: `pied` is an invalid date-time. It should follow the YYYY-MM-DD or RFC 3339 date-time format.", + "code": "invalid_task_before_started_at", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_before_started_at" + } + "#); +} + +macro_rules! assert_valid_summarized_batch { + ($response:expr, $batch_type:literal, $index:literal) => {{ + assert_eq!($response.as_object().unwrap().len(), 5); + assert!($response["batchUid"].as_u64().is_some()); + assert_eq!($response["indexUid"], $index); + assert_eq!($response["status"], "enqueued"); + assert_eq!($response["type"], $batch_type); + let date = $response["enqueuedAt"].as_str().expect("missing date"); + + OffsetDateTime::parse(date, &Rfc3339).unwrap(); + }}; +} + +#[actix_web::test] +async fn test_summarized_batch_view() { + let server = Server::new().await; + let index = server.index("test"); + + let (response, _) = index.create(None).await; + assert_valid_summarized_batch!(response, "indexCreation", "test"); + + let (response, _) = index.update(None).await; + assert_valid_summarized_batch!(response, "indexUpdate", "test"); + + let (response, _) = index.update_settings(json!({})).await; + assert_valid_summarized_batch!(response, "settingsUpdate", "test"); + + let (response, _) = index.update_documents(json!([{"id": 1}]), None).await; + assert_valid_summarized_batch!(response, "documentAdditionOrUpdate", "test"); + + let (response, _) = index.add_documents(json!([{"id": 1}]), None).await; + assert_valid_summarized_batch!(response, "documentAdditionOrUpdate", "test"); + + let (response, _) = index.delete_document(1).await; + assert_valid_summarized_batch!(response, "documentDeletion", "test"); + + let (response, _) = index.clear_all_documents().await; + assert_valid_summarized_batch!(response, "documentDeletion", "test"); + + let (response, _) = index.delete().await; + assert_valid_summarized_batch!(response, "indexDeletion", "test"); +} + +#[actix_web::test] +async fn test_summarized_document_addition_or_update() { + let server = Server::new().await; + let index = server.index("test"); + index.add_documents(json!({ "id": 42, "content": "doggos & fluff" }), None).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.add_documents(json!({ "id": 42, "content": "doggos & fluff" }), Some("id")).await; + index.wait_task(1).await; + let (batch, _) = index.get_batch(1).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 1, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_delete_documents_by_batch() { + let server = Server::new().await; + let index = server.index("test"); + index.delete_batch(vec![1, 2, 3]).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.create(None).await; + index.delete_batch(vec![42]).await; + index.wait_task(2).await; + let (batch, _) = index.get_batch(2).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 2, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_delete_documents_by_filter() { + let server = Server::new().await; + let index = server.index("test"); + + index.delete_document_by_filter(json!({ "filter": "doggo = bernese" })).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.create(None).await; + index.delete_document_by_filter(json!({ "filter": "doggo = bernese" })).await; + index.wait_task(2).await; + let (batch, _) = index.get_batch(2).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 2, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.update_settings(json!({ "filterableAttributes": ["doggo"] })).await; + index.delete_document_by_filter(json!({ "filter": "doggo = bernese" })).await; + index.wait_task(4).await; + let (batch, _) = index.get_batch(4).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 4, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_delete_document_by_id() { + let server = Server::new().await; + let index = server.index("test"); + index.delete_document(1).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.create(None).await; + index.delete_document(42).await; + index.wait_task(2).await; + let (batch, _) = index.get_batch(2).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 2, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_settings_update() { + let server = Server::new().await; + let index = server.index("test"); + // here we should find my payload even in the failed batch. + let (response, code) = index.update_settings(json!({ "rankingRules": ["custom"] })).await; + meili_snap::snapshot!(code, @"400 Bad Request"); + meili_snap::snapshot!(meili_snap::json_string!(response), @r###" + { + "message": "Invalid value at `.rankingRules[0]`: `custom` ranking rule is invalid. Valid ranking rules are words, typo, sort, proximity, attribute, exactness and custom ranking rules.", + "code": "invalid_settings_ranking_rules", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_settings_ranking_rules" + } + "###); + + index.update_settings(json!({ "displayedAttributes": ["doggos", "name"], "filterableAttributes": ["age", "nb_paw_pads"], "sortableAttributes": ["iq"] })).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_index_creation() { + let server = Server::new().await; + let index = server.index("test"); + index.create(None).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.create(Some("doggos")).await; + index.wait_task(1).await; + let (batch, _) = index.get_batch(1).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 1, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_index_deletion() { + let server = Server::new().await; + let index = server.index("test"); + let (ret, _code) = index.delete().await; + let batch = index.wait_task(ret.uid()).await; + snapshot!(batch, + @r###" + { + "uid": "[uid]", + "batchUid": "[batch_uid]", + "indexUid": "test", + "status": "failed", + "type": "indexDeletion", + "canceledBy": null, + "details": { + "deletedDocuments": 0 + }, + "error": { + "message": "Index `test` not found.", + "code": "index_not_found", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#index_not_found" + }, + "duration": "[duration]", + "enqueuedAt": "[date]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "###); + + // is the details correctly set when documents are actually deleted. + // /!\ We need to wait for the document addition to be processed otherwise, if the test runs too slow, + // both batches may get autobatched and the deleted documents count will be wrong. + let (ret, _code) = + index.add_documents(json!({ "id": 42, "content": "doggos & fluff" }), Some("id")).await; + let batch = index.wait_task(ret.uid()).await; + snapshot!(batch, + @r###" + { + "uid": "[uid]", + "batchUid": "[batch_uid]", + "indexUid": "test", + "status": "succeeded", + "type": "documentAdditionOrUpdate", + "canceledBy": null, + "details": { + "receivedDocuments": 1, + "indexedDocuments": 1 + }, + "error": null, + "duration": "[duration]", + "enqueuedAt": "[date]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "###); + + let (ret, _code) = index.delete().await; + let batch = index.wait_task(ret.uid()).await; + snapshot!(batch, + @r###" + { + "uid": "[uid]", + "batchUid": "[batch_uid]", + "indexUid": "test", + "status": "succeeded", + "type": "indexDeletion", + "canceledBy": null, + "details": { + "deletedDocuments": 1 + }, + "error": null, + "duration": "[duration]", + "enqueuedAt": "[date]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "###); + + // What happens when you delete an index that doesn't exists. + let (ret, _code) = index.delete().await; + let batch = index.wait_task(ret.uid()).await; + snapshot!(batch, + @r###" + { + "uid": "[uid]", + "batchUid": "[batch_uid]", + "indexUid": "test", + "status": "failed", + "type": "indexDeletion", + "canceledBy": null, + "details": { + "deletedDocuments": 0 + }, + "error": { + "message": "Index `test` not found.", + "code": "index_not_found", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#index_not_found" + }, + "duration": "[duration]", + "enqueuedAt": "[date]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "###); +} + +#[actix_web::test] +async fn test_summarized_index_update() { + let server = Server::new().await; + let index = server.index("test"); + // If the index doesn't exist yet, we should get errors with or without the primary key. + index.update(None).await; + index.wait_task(0).await; + let (batch, _) = index.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.update(Some("bones")).await; + index.wait_task(1).await; + let (batch, _) = index.get_batch(1).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 1, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + // And run the same two tests once the index do exists. + index.create(None).await; + + index.update(None).await; + index.wait_task(3).await; + let (batch, _) = index.get_batch(3).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 3, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + index.update(Some("bones")).await; + index.wait_task(4).await; + let (batch, _) = index.get_batch(4).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 4, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_index_swap() { + let server = Server::new().await; + server + .index_swap(json!([ + { "indexes": ["doggos", "cattos"] } + ])) + .await; + server.wait_task(0).await; + let (batch, _) = server.get_batch(0).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); + + server.index("doggos").create(None).await; + server.index("cattos").create(None).await; + server + .index_swap(json!([ + { "indexes": ["doggos", "cattos"] } + ])) + .await; + server.wait_task(3).await; + let (batch, _) = server.get_batch(3).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 3, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_batch_cancelation() { + let server = Server::new().await; + let index = server.index("doggos"); + // to avoid being flaky we're only going to cancel an already finished batch :( + index.create(None).await; + index.wait_task(0).await; + server.cancel_tasks("uids=0").await; + index.wait_task(1).await; + let (batch, _) = index.get_batch(1).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 1, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_batch_deletion() { + let server = Server::new().await; + let index = server.index("doggos"); + // to avoid being flaky we're only going to delete an already finished batch :( + index.create(None).await; + index.wait_task(0).await; + server.delete_tasks("uids=0").await; + index.wait_task(1).await; + let (batch, _) = index.get_batch(1).await; + assert_json_snapshot!(batch, + { ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 1, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} + +#[actix_web::test] +async fn test_summarized_dump_creation() { + let server = Server::new().await; + server.create_dump().await; + server.wait_task(0).await; + let (batch, _) = server.get_batch(0).await; + assert_json_snapshot!(batch, + { ".details.dumpUid" => "[dumpUid]", ".duration" => "[duration]", ".enqueuedAt" => "[date]", ".startedAt" => "[date]", ".finishedAt" => "[date]" }, + @r#" + { + "uid": 0, + "duration": "[duration]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "#); +} diff --git a/crates/meilisearch/tests/batches/webhook.rs b/crates/meilisearch/tests/batches/webhook.rs new file mode 100644 index 000000000..b18002eb7 --- /dev/null +++ b/crates/meilisearch/tests/batches/webhook.rs @@ -0,0 +1,129 @@ +//! To test the webhook, we need to spawn a new server with a URL listening for +//! post requests. The webhook handle starts a server and forwards all the +//! received requests into a channel for you to handle. + +use std::sync::Arc; + +use actix_http::body::MessageBody; +use actix_web::dev::{ServiceFactory, ServiceResponse}; +use actix_web::web::{Bytes, Data}; +use actix_web::{post, App, HttpRequest, HttpResponse, HttpServer}; +use meili_snap::snapshot; +use meilisearch::Opt; +use tokio::sync::mpsc; +use url::Url; + +use crate::common::{self, default_settings, Server}; +use crate::json; + +#[post("/")] +async fn forward_body( + req: HttpRequest, + sender: Data>>, + body: Bytes, +) -> HttpResponse { + let headers = req.headers(); + assert_eq!(headers.get("content-type").unwrap(), "application/x-ndjson"); + assert_eq!(headers.get("transfer-encoding").unwrap(), "chunked"); + assert_eq!(headers.get("accept-encoding").unwrap(), "gzip"); + assert_eq!(headers.get("content-encoding").unwrap(), "gzip"); + + let body = body.to_vec(); + sender.send(body).unwrap(); + HttpResponse::Ok().into() +} + +fn create_app( + sender: Arc>>, +) -> actix_web::App< + impl ServiceFactory< + actix_web::dev::ServiceRequest, + Config = (), + Response = ServiceResponse, + Error = actix_web::Error, + InitError = (), + >, +> { + App::new().service(forward_body).app_data(Data::from(sender)) +} + +struct WebhookHandle { + pub server_handle: tokio::task::JoinHandle>, + pub url: String, + pub receiver: mpsc::UnboundedReceiver>, +} + +async fn create_webhook_server() -> WebhookHandle { + let (sender, receiver) = mpsc::unbounded_channel(); + let sender = Arc::new(sender); + + // By listening on the port 0, the system will give us any available port. + let server = + HttpServer::new(move || create_app(sender.clone())).bind(("127.0.0.1", 0)).unwrap(); + let (ip, scheme) = server.addrs_with_scheme()[0]; + let url = format!("{scheme}://{ip}/"); + + let server_handle = tokio::spawn(server.run()); + WebhookHandle { server_handle, url, receiver } +} + +#[actix_web::test] +async fn test_basic_webhook() { + let WebhookHandle { server_handle, url, mut receiver } = create_webhook_server().await; + + let db_path = tempfile::tempdir().unwrap(); + let server = Server::new_with_options(Opt { + task_webhook_url: Some(Url::parse(&url).unwrap()), + ..default_settings(db_path.path()) + }) + .await + .unwrap(); + + let index = server.index("tamo"); + // May be flaky: we're relying on the fact that while the first document addition is processed, the other + // operations will be received and will be batched together. If it doesn't happen it's not a problem + // the rest of the test won't assume anything about the number of tasks per batch. + for i in 0..5 { + let (_, _status) = index.add_documents(json!({ "id": i, "doggo": "bone" }), None).await; + } + + let mut nb_tasks = 0; + while let Some(payload) = receiver.recv().await { + let payload = String::from_utf8(payload).unwrap(); + let jsonl = payload.split('\n'); + for json in jsonl { + if json.is_empty() { + break; // we reached EOF + } + nb_tasks += 1; + let json: serde_json::Value = serde_json::from_str(json).unwrap(); + snapshot!(common::Value(json), + @r###" + { + "uid": "[uid]", + "batchUid": "[batch_uid]", + "indexUid": "tamo", + "status": "succeeded", + "type": "documentAdditionOrUpdate", + "canceledBy": null, + "details": { + "receivedDocuments": 1, + "indexedDocuments": 1 + }, + "error": null, + "duration": "[duration]", + "enqueuedAt": "[date]", + "startedAt": "[date]", + "finishedAt": "[date]" + } + "###); + } + if nb_tasks == 5 { + break; + } + } + + assert!(nb_tasks == 5, "We should have received the 5 tasks but only received {nb_tasks}"); + + server_handle.abort(); +} diff --git a/crates/meilisearch/tests/common/index.rs b/crates/meilisearch/tests/common/index.rs index 221333fd7..b8c1d2824 100644 --- a/crates/meilisearch/tests/common/index.rs +++ b/crates/meilisearch/tests/common/index.rs @@ -136,6 +136,11 @@ impl<'a> Index<'a, Owned> { self.service.get(url).await } + pub async fn list_batches(&self) -> (Value, StatusCode) { + let url = format!("/batches?indexUids={}", self.uid); + self.service.get(url).await + } + pub async fn delete_document(&self, id: u64) -> (Value, StatusCode) { let url = format!("/indexes/{}/documents/{}", urlencode(self.uid.as_ref()), id); self.service.delete(url).await @@ -374,6 +379,30 @@ impl Index<'_, State> { self.service.get(url).await } + pub async fn get_batch(&self, batch_id: u32) -> (Value, StatusCode) { + let url = format!("/batches/{}", batch_id); + self.service.get(url).await + } + + pub async fn filtered_batches( + &self, + types: &[&str], + statuses: &[&str], + canceled_by: &[&str], + ) -> (Value, StatusCode) { + let mut url = format!("/batches?indexUids={}", self.uid); + if !types.is_empty() { + let _ = write!(url, "&types={}", types.join(",")); + } + if !statuses.is_empty() { + let _ = write!(url, "&statuses={}", statuses.join(",")); + } + if !canceled_by.is_empty() { + let _ = write!(url, "&canceledBy={}", canceled_by.join(",")); + } + self.service.get(url).await + } + pub async fn get_document(&self, id: u64, options: Option) -> (Value, StatusCode) { let mut url = format!("/indexes/{}/documents/{}", urlencode(self.uid.as_ref()), id); if let Some(options) = options { diff --git a/crates/meilisearch/tests/common/server.rs b/crates/meilisearch/tests/common/server.rs index 5069c9ea6..49214d646 100644 --- a/crates/meilisearch/tests/common/server.rs +++ b/crates/meilisearch/tests/common/server.rs @@ -330,6 +330,10 @@ impl Server { self.service.get(format!("/tasks?{}", filter)).await } + pub async fn batches_filter(&self, filter: &str) -> (Value, StatusCode) { + self.service.get(format!("/batches?{}", filter)).await + } + pub async fn version(&self) -> (Value, StatusCode) { self.service.get("/version").await } @@ -376,6 +380,11 @@ impl Server { self.service.get(url).await } + pub async fn get_batch(&self, batch_id: u32) -> (Value, StatusCode) { + let url = format!("/batches/{}", batch_id); + self.service.get(url).await + } + pub async fn get_features(&self) -> (Value, StatusCode) { self.service.get("/experimental-features").await } diff --git a/crates/meilisearch/tests/integration.rs b/crates/meilisearch/tests/integration.rs index 78da9825a..85deb9cdf 100644 --- a/crates/meilisearch/tests/integration.rs +++ b/crates/meilisearch/tests/integration.rs @@ -1,4 +1,5 @@ mod auth; +mod batches; mod common; mod dashboard; mod documents; From 5d10c2312bbf5cc34a11bdcc9f2c5a9e52bea963 Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 16:56:52 +0100 Subject: [PATCH 09/22] remove unused file --- crates/meilisearch/tests/batches/webhook.rs | 129 -------------------- 1 file changed, 129 deletions(-) delete mode 100644 crates/meilisearch/tests/batches/webhook.rs diff --git a/crates/meilisearch/tests/batches/webhook.rs b/crates/meilisearch/tests/batches/webhook.rs deleted file mode 100644 index b18002eb7..000000000 --- a/crates/meilisearch/tests/batches/webhook.rs +++ /dev/null @@ -1,129 +0,0 @@ -//! To test the webhook, we need to spawn a new server with a URL listening for -//! post requests. The webhook handle starts a server and forwards all the -//! received requests into a channel for you to handle. - -use std::sync::Arc; - -use actix_http::body::MessageBody; -use actix_web::dev::{ServiceFactory, ServiceResponse}; -use actix_web::web::{Bytes, Data}; -use actix_web::{post, App, HttpRequest, HttpResponse, HttpServer}; -use meili_snap::snapshot; -use meilisearch::Opt; -use tokio::sync::mpsc; -use url::Url; - -use crate::common::{self, default_settings, Server}; -use crate::json; - -#[post("/")] -async fn forward_body( - req: HttpRequest, - sender: Data>>, - body: Bytes, -) -> HttpResponse { - let headers = req.headers(); - assert_eq!(headers.get("content-type").unwrap(), "application/x-ndjson"); - assert_eq!(headers.get("transfer-encoding").unwrap(), "chunked"); - assert_eq!(headers.get("accept-encoding").unwrap(), "gzip"); - assert_eq!(headers.get("content-encoding").unwrap(), "gzip"); - - let body = body.to_vec(); - sender.send(body).unwrap(); - HttpResponse::Ok().into() -} - -fn create_app( - sender: Arc>>, -) -> actix_web::App< - impl ServiceFactory< - actix_web::dev::ServiceRequest, - Config = (), - Response = ServiceResponse, - Error = actix_web::Error, - InitError = (), - >, -> { - App::new().service(forward_body).app_data(Data::from(sender)) -} - -struct WebhookHandle { - pub server_handle: tokio::task::JoinHandle>, - pub url: String, - pub receiver: mpsc::UnboundedReceiver>, -} - -async fn create_webhook_server() -> WebhookHandle { - let (sender, receiver) = mpsc::unbounded_channel(); - let sender = Arc::new(sender); - - // By listening on the port 0, the system will give us any available port. - let server = - HttpServer::new(move || create_app(sender.clone())).bind(("127.0.0.1", 0)).unwrap(); - let (ip, scheme) = server.addrs_with_scheme()[0]; - let url = format!("{scheme}://{ip}/"); - - let server_handle = tokio::spawn(server.run()); - WebhookHandle { server_handle, url, receiver } -} - -#[actix_web::test] -async fn test_basic_webhook() { - let WebhookHandle { server_handle, url, mut receiver } = create_webhook_server().await; - - let db_path = tempfile::tempdir().unwrap(); - let server = Server::new_with_options(Opt { - task_webhook_url: Some(Url::parse(&url).unwrap()), - ..default_settings(db_path.path()) - }) - .await - .unwrap(); - - let index = server.index("tamo"); - // May be flaky: we're relying on the fact that while the first document addition is processed, the other - // operations will be received and will be batched together. If it doesn't happen it's not a problem - // the rest of the test won't assume anything about the number of tasks per batch. - for i in 0..5 { - let (_, _status) = index.add_documents(json!({ "id": i, "doggo": "bone" }), None).await; - } - - let mut nb_tasks = 0; - while let Some(payload) = receiver.recv().await { - let payload = String::from_utf8(payload).unwrap(); - let jsonl = payload.split('\n'); - for json in jsonl { - if json.is_empty() { - break; // we reached EOF - } - nb_tasks += 1; - let json: serde_json::Value = serde_json::from_str(json).unwrap(); - snapshot!(common::Value(json), - @r###" - { - "uid": "[uid]", - "batchUid": "[batch_uid]", - "indexUid": "tamo", - "status": "succeeded", - "type": "documentAdditionOrUpdate", - "canceledBy": null, - "details": { - "receivedDocuments": 1, - "indexedDocuments": 1 - }, - "error": null, - "duration": "[duration]", - "enqueuedAt": "[date]", - "startedAt": "[date]", - "finishedAt": "[date]" - } - "###); - } - if nb_tasks == 5 { - break; - } - } - - assert!(nb_tasks == 5, "We should have received the 5 tasks but only received {nb_tasks}"); - - server_handle.abort(); -} From 229fa0f9021932aea19289e5b8a17fffdb78364a Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 17:06:00 +0100 Subject: [PATCH 10/22] implements the batch details --- crates/index-scheduler/src/insta_snapshot.rs | 3 +- .../cancel_processed.snap | 2 +- .../aborted_indexation.snap | 2 +- .../cancel_mix_of_tasks/cancel_processed.snap | 4 +- .../first_task_processed.snap | 2 +- ...rocessing_second_task_cancel_enqueued.snap | 2 +- .../cancel_processed.snap | 2 +- .../cancel_processed.snap | 2 +- .../cancel_processed.snap | 4 +- .../initial_task_processed.snap | 2 +- .../all_tasks_processed.snap | 12 +- .../once_everything_is_processed.snap | 2 +- .../after_processing_the_batch.snap | 2 +- .../before_index_creation.snap | 2 +- .../both_task_succeeded.snap | 4 +- .../2.snap | 2 +- .../after_failing_the_deletion.snap | 2 +- .../after_last_successful_addition.snap | 4 +- .../document_addition_failed.snap | 2 +- .../after_adding_the_documents.snap | 4 +- .../after_adding_the_settings.snap | 2 +- .../after_removing_the_documents.snap | 6 +- .../registered_the_document_deletions.snap | 4 +- .../index_creation_failed.snap | 2 +- .../task_successfully_processed.snap | 2 +- .../Intel to kefir succeeds.snap | 6 +- .../lib.rs/import_vectors/Intel to kefir.snap | 4 +- .../import_vectors/adding Intel succeeds.snap | 4 +- .../import_vectors/after adding Intel.snap | 2 +- .../settings_update_processed_vectors.snap | 2 +- .../index_creation_failed.snap | 2 +- .../processed_the_first_task.snap | 2 +- .../processed_the_second_task.snap | 4 +- .../processed_the_third_task.snap | 6 +- .../first.snap | 2 +- .../fourth.snap | 8 +- .../second.snap | 4 +- .../third.snap | 6 +- .../query_batches_canceled_by/start.snap | 4 +- .../processed_all_tasks.snap | 6 +- .../lib.rs/query_batches_simple/end.snap | 6 +- .../after-processing-everything.snap | 8 +- .../lib.rs/query_tasks_canceled_by/start.snap | 4 +- .../processed_all_tasks.snap | 6 +- .../lib.rs/query_tasks_simple/end.snap | 6 +- .../lib.rs/swap_indexes/create_a.snap | 2 +- .../lib.rs/swap_indexes/create_b.snap | 4 +- .../lib.rs/swap_indexes/create_c.snap | 6 +- .../lib.rs/swap_indexes/create_d.snap | 8 +- .../swap_indexes/first_swap_processed.snap | 10 +- .../swap_indexes/first_swap_registered.snap | 8 +- .../swap_indexes/second_swap_processed.snap | 12 +- .../third_empty_swap_processed.snap | 14 +- .../swap_indexes/two_swaps_registered.snap | 8 +- .../after_the_index_creation.snap | 8 +- .../first_swap_failed.snap | 10 +- .../initial_tasks_processed.snap | 8 +- .../initial_tasks_processed.snap | 2 +- .../task_deletion_processed.snap | 2 +- .../after_registering_the_task_deletion.snap | 2 +- .../initial_tasks_processed.snap | 2 +- .../task_deletion_processed.snap | 2 +- .../task_deletion_done.snap | 2 +- .../after_processing_the_10_tasks.snap | 4 +- .../after_registering_the_10_tasks.snap | 2 +- .../processed_the_first_task.snap | 2 +- .../after_registering_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 22 +-- .../five_tasks_processed.snap | 12 +- .../processed_the_first_task.snap | 2 +- .../after_processing_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 20 +-- .../five_tasks_processed.snap | 10 +- .../all_tasks_processed.snap | 4 +- .../only_first_task_failed.snap | 2 +- .../after_registering_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 4 +- .../processed_the_first_task.snap | 2 +- .../fifth_task_succeeds.snap | 8 +- .../first_and_second_task_fails.snap | 2 +- .../fourth_task_fails.snap | 6 +- .../third_task_succeeds.snap | 4 +- .../only_first_task_succeed.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_fails.snap | 6 +- .../only_first_task_succeed.snap | 2 +- .../second_and_third_tasks_fails.snap | 4 +- .../all_other_tasks_succeeds.snap | 8 +- .../first_task_fails.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 6 +- .../all_other_tasks_succeeds.snap | 8 +- .../first_task_succeed.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 6 +- .../lib.rs/test_document_replace/2.snap | 2 +- .../all_tasks_processed.snap | 20 +-- .../five_tasks_processed.snap | 10 +- .../lib.rs/test_document_update/2.snap | 2 +- .../all_tasks_processed.snap | 20 +-- .../five_tasks_processed.snap | 10 +- .../all_tasks_processed.snap | 20 +-- .../five_tasks_processed.snap | 10 +- .../settings_update_processed.snap | 2 +- crates/index-scheduler/src/utils.rs | 18 ++- crates/meilisearch-types/src/batch_view.rs | 3 + crates/meilisearch-types/src/batches.rs | 4 + crates/meilisearch-types/src/settings.rs | 64 +++++++++ crates/meilisearch-types/src/task_view.rs | 126 +++++++++++++++++- crates/milli/src/update/settings.rs | 8 ++ 110 files changed, 493 insertions(+), 275 deletions(-) diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index af56fe467..1d5018469 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -349,12 +349,13 @@ pub fn snapshot_canceled_by(rtxn: &RoTxn, db: Database String { let mut snap = String::new(); - let Batch { uid, started_at, finished_at } = batch; + let Batch { uid, details, started_at, finished_at } = batch; if let Some(finished_at) = finished_at { assert!(finished_at > started_at); } snap.push('{'); snap.push_str(&format!("uid: {uid}, ")); + snap.push_str(&format!("details: {}, ", serde_json::to_string(details).unwrap())); snap.push('}'); snap } diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap index d19ea3960..82bb48bc4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap @@ -40,7 +40,7 @@ catto [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap index 55b4275c7..ef4c72d06 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap @@ -46,7 +46,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap index 4989ef2ff..de85afb77 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap @@ -50,8 +50,8 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":2,"indexedDocuments":0,"matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap index 524f865d8..96905e096 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap @@ -42,7 +42,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap index c67c45f02..f56849774 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap @@ -45,7 +45,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap index b619399bf..b81db3316 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap @@ -39,7 +39,7 @@ canceled [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"matchedTasks":1,"canceledTasks":1,"originalFilter":"cancel dump"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap index c8f661fb0..bf206e539 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap @@ -41,7 +41,7 @@ catto: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap index 94465298d..8f141b214 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap @@ -41,8 +41,8 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"matchedTasks":1,"canceledTasks":0,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap index 8cddcf06d..9f2fac934 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap @@ -36,7 +36,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap index b024305dd..c903fef85 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap @@ -61,12 +61,12 @@ girafos: { number_of_documents: 0, field_distribution: {} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {}, } +3 {uid: 3, details: {"deletedDocuments":0}, } +4 {uid: 4, details: {"deletedDocuments":0}, } +5 {uid: 5, details: {"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap index 52fefbbec..87e4bc88d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap index 73f2730d2..19dc4103e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":3,"indexedDocuments":3,"providedIds":2,"deletedDocuments":2}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap index 66d073dc0..770a22457 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap @@ -42,7 +42,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap index 648c66927..b6c38da20 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap @@ -43,8 +43,8 @@ doggos [0,1,2,] [timestamp] [1,2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap index 91b1ebd93..d26ed4124 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap @@ -38,7 +38,7 @@ doggos [0,1,] [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 1ea3bdbd4..891f77b63 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -38,7 +38,7 @@ doggos [0,1,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index f3d7e2379..1138c5e03 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -42,8 +42,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index f79a7fed1..741a02636 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -35,7 +35,7 @@ doggos [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap index 37ef7a5cb..3201eff58 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap @@ -41,8 +41,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap index dbe571e1b..d7adfdc46 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index 762173c27..226fde294 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -53,9 +53,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } +2 {uid: 2, details: {"providedIds":1,"deletedDocuments":2,"originalFilter":"\"catto EXISTS\""}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap index 424218e1c..68058b616 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap @@ -50,8 +50,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 34f6ad7fd..845de58de 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap index 52fefbbec..87e4bc88d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap index cc392afbb..4b7c1a1f9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap @@ -45,9 +45,9 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap index 1e4534935..9ee0447d6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap index 41e464287..be04ea541 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap @@ -41,8 +41,8 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap index 03c7b3a5a..2229139d7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap index 7bdb75143..a9e162b9c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index fdd8e1f1d..52bcfe6f6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap index 6bc6f22fd..6a5b847e9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap @@ -42,7 +42,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap index 747d64903..8b4b88a8d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap @@ -45,8 +45,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap index b6c419847..19c9957ed 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap @@ -46,9 +46,9 @@ cattos: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap index b5894122f..6762b0707 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap @@ -43,7 +43,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap index 93fc7c824..9fdb5aceb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap @@ -49,10 +49,10 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"deletedDocuments":0}, } +2 {uid: 2, details: {"deletedDocuments":0}, } +3 {uid: 3, details: {"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap index fa00c237b..b7d505301 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap @@ -45,8 +45,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap index f9c3166ad..aaa714bde 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap @@ -47,9 +47,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"deletedDocuments":0}, } +2 {uid: 2, details: {"deletedDocuments":0}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap index 3af67a73c..a48246ae6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap @@ -49,8 +49,8 @@ catto: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"primaryKey":"mouse"}, } +1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap index cb12fa554..ebb20f2e7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap @@ -48,9 +48,9 @@ whalo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"primaryKey":"bone"}, } +1 {uid: 1, details: {"primaryKey":"plankton"}, } +2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap index 7325520eb..bbe89cf36 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap @@ -48,9 +48,9 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"primaryKey":"mouse"}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, } +2 {uid: 2, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap index 2bf1b4509..2783c3049 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap @@ -53,10 +53,10 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"mouse"}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, } +2 {uid: 2, details: {}, } +3 {uid: 3, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap index 3af67a73c..a48246ae6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap @@ -49,8 +49,8 @@ catto: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"primaryKey":"mouse"}, } +1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap index cb12fa554..ebb20f2e7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap @@ -48,9 +48,9 @@ whalo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"primaryKey":"bone"}, } +1 {uid: 1, details: {"primaryKey":"plankton"}, } +2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index 7325520eb..bbe89cf36 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -48,9 +48,9 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"primaryKey":"mouse"}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, } +2 {uid: 2, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap index 639972a3e..84566cd49 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap @@ -45,7 +45,7 @@ a: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap index 4b94276ab..a5581d589 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap @@ -48,8 +48,8 @@ b: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap index 4ab09f46c..9ad7e5505 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap @@ -51,9 +51,9 @@ c: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap index 41d8bec15..cd578260c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap index 108a28b11..dd31bb637 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap @@ -61,11 +61,11 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap index 02b746053..74fc1b4f5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap @@ -57,10 +57,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap index 0209f57bc..792707b06 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap @@ -63,12 +63,12 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } +5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap index bb165d824..342797b32 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap @@ -67,13 +67,13 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [6,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } +5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, } +6 {uid: 6, details: {"swaps":[]}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap index 063b97d62..15cb92534 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap @@ -59,10 +59,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap index 41d8bec15..cd578260c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index 3bf223e41..148f95abb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -62,11 +62,11 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } +4 {uid: 4, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap index 41d8bec15..cd578260c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"primaryKey":"id"}, } +1 {uid: 1, details: {"primaryKey":"id"}, } +2 {uid: 2, details: {"primaryKey":"id"}, } +3 {uid: 3, details: {"primaryKey":"id"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap index e88870283..671c4c16e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 24844c3f8..8ab24e82a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -41,7 +41,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,3,] ---------------------------------------------------------------------- ### All Batches: -1 {uid: 1, } +1 {uid: 1, details: {"matchedTasks":2,"deletedTasks":1,"originalFilter":"test_query&test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 1 [2,3,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap index 7dac66431..ff0c65910 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap @@ -42,7 +42,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap index e88870283..671c4c16e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index 97106df1b..570a8e517 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -1 {uid: 1, } +1 {uid: 1, details: {"matchedTasks":1,"deletedTasks":1,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 1 [2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap index 3fd3ca34b..de7430ddb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap @@ -44,7 +44,7 @@ doggo [2,] [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"matchedTasks":2,"deletedTasks":0,"originalFilter":"test_query"}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [3,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap index 8ca3aab2b..eaf694e4a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap @@ -59,8 +59,8 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap index b6a0c00c9..7aee46969 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap index 1f77245be..5399443a9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap index abc31b0cd..2c5305088 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap index cc716cfc8..766d2624a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap @@ -77,17 +77,17 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } -7 {uid: 7, } -8 {uid: 8, } -9 {uid: 9, } -10 {uid: 10, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } +10 {uid: 10, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap index c68517991..7bc408a14 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap @@ -67,12 +67,12 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap index f4c3cdc65..6d9343ce5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index fe329cb55..3a6a394dc 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index b3f8a48a5..d95d8f8db 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -71,16 +71,16 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } -7 {uid: 7, } -8 {uid: 8, } -9 {uid: 9, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {}, } +3 {uid: 3, details: {}, } +4 {uid: 4, details: {}, } +5 {uid: 5, details: {}, } +6 {uid: 6, details: {}, } +7 {uid: 7, details: {}, } +8 {uid: 8, details: {}, } +9 {uid: 9, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index 468eac198..c8e2fd93b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -61,11 +61,11 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {}, } +3 {uid: 3, details: {}, } +4 {uid: 4, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index 92682a4e2..700044b79 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -57,8 +57,8 @@ doggos: { number_of_documents: 9, field_distribution: {"doggo": 9, "id": 9} } [timestamp] [1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":9,"indexedDocuments":9}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index 87d14ae51..e08954bca 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap index c61ba5983..78058a92d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap index 723a387cd..68113fc86 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap @@ -59,8 +59,8 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap index 1f77245be..5399443a9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index f3ee85d54..281bdd96a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -51,10 +51,10 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "id": 2} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index ded62c6e1..0a2ff55b1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -44,7 +44,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 0d4ea85be..74353f21b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -49,9 +49,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index 91ad54ff1..1d7c61d91 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -47,8 +47,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap index d43603f3b..f01d8adf3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap @@ -40,7 +40,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index 913c3e1d9..5948f1c90 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index 5d0251da3..87b14c7be 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -45,9 +45,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap index a6d327add..e94d544bb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap @@ -40,7 +40,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 4d7af4a8d..6c3c13305 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index 1fcaefeed..2cf46c611 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -53,10 +53,10 @@ doggos: { number_of_documents: 4, field_distribution: {"doggo": 4, "paw": 4} } [timestamp] [3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index e13c0f6ab..4d8f1fad9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -46,7 +46,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index a76a5983e..3ee347076 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -48,8 +48,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index 507ebe04d..13f20f31b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -51,9 +51,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "paw": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index 90807eeb8..dd91d7c5d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -53,10 +53,10 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "doggoid": 5} [timestamp] [3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap index bdfc30547..525c83371 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap @@ -46,7 +46,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index 5c34f53c0..6ba811363 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -49,8 +49,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index 3c18f87b2..a397c7fdd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -51,9 +51,9 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "doggoid": 2} [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap index 916f0ae0f..277bc8aff 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap @@ -54,7 +54,7 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap index 0ea35496e..4b4ace120 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } -7 {uid: 7, } -8 {uid: 8, } -9 {uid: 9, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap index 140f540c6..bea6f75ce 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap index 502493423..b98540594 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap @@ -54,7 +54,7 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap index 924033507..d30a8b0c2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } -7 {uid: 7, } -8 {uid: 8, } -9 {uid: 9, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap index c762ac7f0..0b608c691 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap index 392ea405a..8324b62ae 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } -5 {uid: 5, } -6 {uid: 6, } -7 {uid: 7, } -8 {uid: 8, } -9 {uid: 9, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap index cd08d9289..f2a03bcab 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } -1 {uid: 1, } -2 {uid: 2, } -3 {uid: 3, } -4 {uid: 4, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap index a5b4849a9..bea2d5ab1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, } +0 {uid: 0, details: {"embedders":{"default":{"source":"rest","apiKey":"MyXXXX...","dimensions":4,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"}}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index edb413600..322d15ea9 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -7,6 +7,7 @@ use meilisearch_types::batches::{Batch, BatchId}; use meilisearch_types::heed::types::DecodeIgnore; use meilisearch_types::heed::{Database, RoTxn, RwTxn}; use meilisearch_types::milli::CboRoaringBitmapCodec; +use meilisearch_types::task_view::DetailsView; use meilisearch_types::tasks::{Details, IndexSwap, Kind, KindWithContent, Status}; use roaring::{MultiOps, RoaringBitmap}; use time::OffsetDateTime; @@ -18,6 +19,8 @@ use crate::{Error, IndexScheduler, Result, Task, TaskId, BEI128}; #[derive(Debug, Clone)] pub(crate) struct ProcessingBatch { pub uid: BatchId, + pub details: DetailsView, + pub statuses: HashSet, pub kinds: HashSet, pub indexes: HashSet, @@ -35,6 +38,8 @@ impl ProcessingBatch { Self { uid, + details: DetailsView::default(), + statuses, kinds: HashSet::default(), indexes: HashSet::default(), @@ -47,6 +52,12 @@ impl ProcessingBatch { /// Remove the Processing status and update the real statuses of the tasks. pub fn update(&mut self, task: &Task) { + // Craft an aggregation of the details of all the tasks encountered in this batch. + if task.status != Status::Failed { + if let Some(ref details) = task.details { + self.details.accumulate(&DetailsView::from(details.clone())); + } + } self.statuses.clear(); self.statuses.insert(task.status); } @@ -117,7 +128,12 @@ impl IndexScheduler { self.all_batches.put( wtxn, &batch.uid, - &Batch { uid: batch.uid, started_at: batch.started_at, finished_at: Some(finished_at) }, + &Batch { + uid: batch.uid, + details: batch.details, + started_at: batch.started_at, + finished_at: Some(finished_at), + }, )?; self.batch_to_tasks_mapping.put(wtxn, &batch.uid, tasks)?; diff --git a/crates/meilisearch-types/src/batch_view.rs b/crates/meilisearch-types/src/batch_view.rs index 15e1f8ab9..684fc48e6 100644 --- a/crates/meilisearch-types/src/batch_view.rs +++ b/crates/meilisearch-types/src/batch_view.rs @@ -3,6 +3,7 @@ use time::{Duration, OffsetDateTime}; use crate::{ batches::{Batch, BatchId}, + task_view::DetailsView, tasks::serialize_duration, }; @@ -10,6 +11,7 @@ use crate::{ #[serde(rename_all = "camelCase")] pub struct BatchView { pub uid: BatchId, + pub details: DetailsView, #[serde(serialize_with = "serialize_duration", default)] pub duration: Option, #[serde(with = "time::serde::rfc3339", default)] @@ -22,6 +24,7 @@ impl BatchView { pub fn from_batch(batch: &Batch) -> Self { Self { uid: batch.uid, + details: batch.details.clone(), duration: batch.finished_at.map(|finished_at| finished_at - batch.started_at), started_at: batch.started_at, finished_at: batch.finished_at, diff --git a/crates/meilisearch-types/src/batches.rs b/crates/meilisearch-types/src/batches.rs index 8a439c59f..c5c4530ec 100644 --- a/crates/meilisearch-types/src/batches.rs +++ b/crates/meilisearch-types/src/batches.rs @@ -1,6 +1,8 @@ use serde::{Deserialize, Serialize}; use time::OffsetDateTime; +use crate::task_view::DetailsView; + pub type BatchId = u32; #[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] @@ -8,6 +10,8 @@ pub type BatchId = u32; pub struct Batch { pub uid: BatchId, + pub details: DetailsView, + #[serde(with = "time::serde::rfc3339")] pub started_at: OffsetDateTime, #[serde(with = "time::serde::rfc3339::option")] diff --git a/crates/meilisearch-types/src/settings.rs b/crates/meilisearch-types/src/settings.rs index 9e7a2bc15..e3803fa28 100644 --- a/crates/meilisearch-types/src/settings.rs +++ b/crates/meilisearch-types/src/settings.rs @@ -378,6 +378,64 @@ impl Settings { self.embedders = Setting::Set(configs); Ok(self) } + + pub fn merge(&mut self, other: &Self) { + // For most settings only the latest version is kept + *self = Self { + displayed_attributes: other + .displayed_attributes + .clone() + .or(self.displayed_attributes.clone()), + searchable_attributes: other + .searchable_attributes + .clone() + .or(self.searchable_attributes.clone()), + filterable_attributes: other + .filterable_attributes + .clone() + .or(self.filterable_attributes.clone()), + sortable_attributes: other + .sortable_attributes + .clone() + .or(self.sortable_attributes.clone()), + ranking_rules: other.ranking_rules.clone().or(self.ranking_rules.clone()), + stop_words: other.stop_words.clone().or(self.stop_words.clone()), + non_separator_tokens: other + .non_separator_tokens + .clone() + .or(self.non_separator_tokens.clone()), + separator_tokens: other.separator_tokens.clone().or(self.separator_tokens.clone()), + dictionary: other.dictionary.clone().or(self.dictionary.clone()), + synonyms: other.synonyms.clone().or(self.synonyms.clone()), + distinct_attribute: other + .distinct_attribute + .clone() + .or(self.distinct_attribute.clone()), + proximity_precision: other.proximity_precision.or(self.proximity_precision), + typo_tolerance: other.typo_tolerance.clone().or(self.typo_tolerance.clone()), + faceting: other.faceting.clone().or(self.faceting.clone()), + pagination: other.pagination.clone().or(self.pagination.clone()), + search_cutoff_ms: other.search_cutoff_ms.or(self.search_cutoff_ms), + localized_attributes: other + .localized_attributes + .clone() + .or(self.localized_attributes.clone()), + embedders: match (self.embedders.clone(), other.embedders.clone()) { + (Setting::NotSet, set) | (set, Setting::NotSet) => set, + (Setting::Set(_) | Setting::Reset, Setting::Reset) => Setting::Reset, + (Setting::Reset, Setting::Set(embedder)) => Setting::Set(embedder), + + // If both are set we must merge the embeddings settings + (Setting::Set(mut this), Setting::Set(other)) => { + for (k, v) in other { + this.insert(k, v); + } + Setting::Set(this) + } + }, + _kind: PhantomData, + } + } } #[derive(Debug, Clone, Serialize, Deserialize)] @@ -868,6 +926,12 @@ impl From for ProximityPrecision { #[derive(Debug, Clone, Default, Deserialize, PartialEq, Eq)] pub struct WildcardSetting(Setting>); +impl WildcardSetting { + pub fn or(self, other: Self) -> Self { + Self(self.0.or(other.0)) + } +} + impl From>> for WildcardSetting { fn from(setting: Setting>) -> Self { Self(setting) diff --git a/crates/meilisearch-types/src/task_view.rs b/crates/meilisearch-types/src/task_view.rs index 0cc127c0d..64dbd58f7 100644 --- a/crates/meilisearch-types/src/task_view.rs +++ b/crates/meilisearch-types/src/task_view.rs @@ -1,5 +1,5 @@ use milli::Object; -use serde::Serialize; +use serde::{Deserialize, Serialize}; use time::{Duration, OffsetDateTime}; use crate::batches::BatchId; @@ -50,7 +50,7 @@ impl TaskView { } } -#[derive(Default, Debug, PartialEq, Eq, Clone, Serialize)] +#[derive(Default, Debug, PartialEq, Eq, Clone, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct DetailsView { #[serde(skip_serializing_if = "Option::is_none")] @@ -86,6 +86,128 @@ pub struct DetailsView { pub swaps: Option>, } +impl DetailsView { + pub fn accumulate(&mut self, other: &Self) { + *self = Self { + received_documents: match (self.received_documents, other.received_documents) { + (None, None) => None, + (None, Some(doc)) | (Some(doc), None) => Some(doc), + (Some(left), Some(right)) => Some(left + right), + }, + indexed_documents: match (self.indexed_documents, other.indexed_documents) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(doc))) | (Some(Some(doc)), None | Some(None)) => { + Some(Some(doc)) + } + (Some(Some(left)), Some(Some(right))) => Some(Some(left + right)), + }, + edited_documents: match (self.edited_documents, other.edited_documents) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(doc))) | (Some(Some(doc)), None | Some(None)) => { + Some(Some(doc)) + } + (Some(Some(left)), Some(Some(right))) => Some(Some(left + right)), + }, + primary_key: match (&self.primary_key, &other.primary_key) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(doc))) | (Some(Some(doc)), None | Some(None)) => { + Some(Some(doc.to_string())) + } + // In the case we receive multiple primary keys (which shouldn't happens) we only return the first one encountered. + (Some(Some(left)), Some(Some(_right))) => Some(Some(left.to_string())), + }, + provided_ids: match (self.provided_ids, other.provided_ids) { + (None, None) => None, + (None, Some(ids)) | (Some(ids), None) => Some(ids), + (Some(left), Some(right)) => Some(left + right), + }, + deleted_documents: match (self.deleted_documents, other.deleted_documents) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(doc))) | (Some(Some(doc)), None | Some(None)) => { + Some(Some(doc)) + } + (Some(Some(left)), Some(Some(right))) => Some(Some(left + right)), + }, + matched_tasks: match (self.matched_tasks, other.matched_tasks) { + (None, None) => None, + (None, Some(task)) | (Some(task), None) => Some(task), + (Some(left), Some(right)) => Some(left + right), + }, + canceled_tasks: match (self.canceled_tasks, other.canceled_tasks) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(task))) | (Some(Some(task)), None | Some(None)) => { + Some(Some(task)) + } + (Some(Some(left)), Some(Some(right))) => Some(Some(left + right)), + }, + deleted_tasks: match (self.deleted_tasks, other.deleted_tasks) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(task))) | (Some(Some(task)), None | Some(None)) => { + Some(Some(task)) + } + (Some(Some(left)), Some(Some(right))) => Some(Some(left + right)), + }, + original_filter: match (&self.original_filter, &other.original_filter) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(filter))) + | (Some(Some(filter)), None | Some(None)) => Some(Some(filter.to_string())), + // In this case, we cannot really merge both filters or return an array so we're going to return + // all the conditions one after the other. + (Some(Some(left)), Some(Some(right))) => Some(Some(format!("{left}&{right}"))), + }, + dump_uid: match (&self.dump_uid, &other.dump_uid) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(dump_uid))) + | (Some(Some(dump_uid)), None | Some(None)) => Some(Some(dump_uid.to_string())), + // We should never be able to batch multiple dumps at the same time. So we return + // the first one we encounter but that shouldn't be an issue anyway. + (Some(Some(left)), Some(Some(_right))) => Some(Some(left.to_string())), + }, + context: match (&self.context, &other.context) { + (None, None) => None, + (None, Some(None)) | (Some(None), None) | (Some(None), Some(None)) => Some(None), + (None | Some(None), Some(Some(ctx))) | (Some(Some(ctx)), None | Some(None)) => { + Some(Some(ctx.clone())) + } + // We should never be able to batch multiple documents edited at the same time. So we return + // the first one we encounter but that shouldn't be an issue anyway. + (Some(Some(left)), Some(Some(_right))) => Some(Some(left.clone())), + }, + function: match (&self.function, &other.function) { + (None, None) => None, + (None, Some(fun)) | (Some(fun), None) => Some(fun.to_string()), + // We should never be able to batch multiple documents edited at the same time. So we return + // the first one we encounter but that shouldn't be an issue anyway. + (Some(left), Some(_right)) => Some(left.to_string()), + }, + settings: match (self.settings.clone(), other.settings.clone()) { + (None, None) => None, + (None, Some(settings)) | (Some(settings), None) => Some(settings), + (Some(mut left), Some(right)) => { + left.merge(&right); + Some(left) + } + }, + swaps: match (self.swaps.clone(), other.swaps.clone()) { + (None, None) => None, + (None, Some(swaps)) | (Some(swaps), None) => Some(swaps), + (Some(mut left), Some(mut right)) => { + left.append(&mut right); + Some(left) + } + }, + } + } +} + impl From
for DetailsView { fn from(details: Details) -> Self { match details { diff --git a/crates/milli/src/update/settings.rs b/crates/milli/src/update/settings.rs index 6e2b53d58..a3e83ad16 100644 --- a/crates/milli/src/update/settings.rs +++ b/crates/milli/src/update/settings.rs @@ -96,6 +96,14 @@ impl Setting { } } + /// Returns other if self is not set. + pub fn or(self, other: Self) -> Self { + match self { + Setting::Set(_) | Setting::Reset => self, + Setting::NotSet => other, + } + } + /// Returns `true` if applying the new setting changed this setting pub fn apply(&mut self, new: Self) -> bool where From 4abcd9c04eb9e1ab62426189778794844106ce4f Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 18:19:41 +0100 Subject: [PATCH 11/22] add some stats on the batches --- crates/index-scheduler/src/insta_snapshot.rs | 3 +- crates/index-scheduler/src/lib.rs | 19 +- .../cancel_processed.snap | 7 +- .../aborted_indexation.snap | 2 +- .../cancel_mix_of_tasks/cancel_processed.snap | 9 +- .../first_task_processed.snap | 2 +- ...rocessing_second_task_cancel_enqueued.snap | 2 +- .../cancel_processed.snap | 7 +- .../cancel_processed.snap | 7 +- .../cancel_processed.snap | 4 +- .../initial_task_processed.snap | 2 +- .../all_tasks_processed.snap | 12 +- .../once_everything_is_processed.snap | 2 +- .../after_processing_the_batch.snap | 2 +- .../before_index_creation.snap | 2 +- .../both_task_succeeded.snap | 4 +- .../2.snap | 2 +- .../after_failing_the_deletion.snap | 2 +- .../after_last_successful_addition.snap | 4 +- .../document_addition_failed.snap | 2 +- .../after_adding_the_documents.snap | 4 +- .../after_adding_the_settings.snap | 2 +- .../after_removing_the_documents.snap | 7 +- .../registered_the_document_deletions.snap | 4 +- .../index_creation_failed.snap | 2 +- .../task_successfully_processed.snap | 2 +- .../Intel to kefir succeeds.snap | 6 +- .../lib.rs/import_vectors/Intel to kefir.snap | 4 +- .../import_vectors/adding Intel succeeds.snap | 4 +- .../import_vectors/after adding Intel.snap | 2 +- .../settings_update_processed_vectors.snap | 2 +- .../index_creation_failed.snap | 2 +- .../processed_the_first_task.snap | 2 +- .../processed_the_second_task.snap | 4 +- .../processed_the_third_task.snap | 6 +- .../first.snap | 2 +- .../fourth.snap | 8 +- .../second.snap | 4 +- .../third.snap | 6 +- .../query_batches_canceled_by/start.snap | 9 +- .../processed_all_tasks.snap | 6 +- .../lib.rs/query_batches_simple/end.snap | 6 +- .../after-processing-everything.snap | 8 +- .../lib.rs/query_tasks_canceled_by/start.snap | 9 +- .../processed_all_tasks.snap | 6 +- .../lib.rs/query_tasks_simple/end.snap | 6 +- .../lib.rs/swap_indexes/create_a.snap | 2 +- .../lib.rs/swap_indexes/create_b.snap | 4 +- .../lib.rs/swap_indexes/create_c.snap | 6 +- .../lib.rs/swap_indexes/create_d.snap | 8 +- .../swap_indexes/first_swap_processed.snap | 10 +- .../swap_indexes/first_swap_registered.snap | 8 +- .../swap_indexes/second_swap_processed.snap | 12 +- .../third_empty_swap_processed.snap | 14 +- .../swap_indexes/two_swaps_registered.snap | 8 +- .../after_the_index_creation.snap | 8 +- .../first_swap_failed.snap | 10 +- .../initial_tasks_processed.snap | 8 +- .../initial_tasks_processed.snap | 2 +- .../task_deletion_processed.snap | 2 +- .../after_registering_the_task_deletion.snap | 2 +- .../initial_tasks_processed.snap | 2 +- .../task_deletion_processed.snap | 2 +- .../task_deletion_done.snap | 2 +- .../after_processing_the_10_tasks.snap | 4 +- .../after_registering_the_10_tasks.snap | 2 +- .../processed_the_first_task.snap | 2 +- .../after_registering_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 22 +- .../five_tasks_processed.snap | 12 +- .../processed_the_first_task.snap | 2 +- .../after_processing_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 20 +- .../five_tasks_processed.snap | 10 +- .../all_tasks_processed.snap | 4 +- .../only_first_task_failed.snap | 2 +- .../after_registering_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 4 +- .../processed_the_first_task.snap | 2 +- .../fifth_task_succeeds.snap | 8 +- .../first_and_second_task_fails.snap | 2 +- .../fourth_task_fails.snap | 6 +- .../third_task_succeeds.snap | 4 +- .../only_first_task_succeed.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_fails.snap | 6 +- .../only_first_task_succeed.snap | 2 +- .../second_and_third_tasks_fails.snap | 4 +- .../all_other_tasks_succeeds.snap | 8 +- .../first_task_fails.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 6 +- .../all_other_tasks_succeeds.snap | 8 +- .../first_task_succeed.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 6 +- .../lib.rs/test_document_replace/2.snap | 2 +- .../all_tasks_processed.snap | 20 +- .../five_tasks_processed.snap | 10 +- .../lib.rs/test_document_update/2.snap | 2 +- .../all_tasks_processed.snap | 20 +- .../five_tasks_processed.snap | 10 +- .../all_tasks_processed.snap | 20 +- .../five_tasks_processed.snap | 10 +- .../settings_update_processed.snap | 2 +- crates/index-scheduler/src/utils.rs | 68 +++- crates/meilisearch-types/src/batch_view.rs | 6 +- crates/meilisearch-types/src/batches.rs | 22 +- crates/meilisearch-types/src/tasks.rs | 8 +- crates/meilisearch/tests/batches/mod.rs | 312 ++++++++++++++++++ 110 files changed, 688 insertions(+), 323 deletions(-) diff --git a/crates/index-scheduler/src/insta_snapshot.rs b/crates/index-scheduler/src/insta_snapshot.rs index 1d5018469..40992a874 100644 --- a/crates/index-scheduler/src/insta_snapshot.rs +++ b/crates/index-scheduler/src/insta_snapshot.rs @@ -349,13 +349,14 @@ pub fn snapshot_canceled_by(rtxn: &RoTxn, db: Database String { let mut snap = String::new(); - let Batch { uid, details, started_at, finished_at } = batch; + let Batch { uid, details, stats, started_at, finished_at } = batch; if let Some(finished_at) = finished_at { assert!(finished_at > started_at); } snap.push('{'); snap.push_str(&format!("uid: {uid}, ")); snap.push_str(&format!("details: {}, ", serde_json::to_string(details).unwrap())); + snap.push_str(&format!("stats: {}, ", serde_json::to_string(stats).unwrap())); snap.push('}'); snap } diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 7ee799bd4..f66f147e2 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -1589,9 +1589,9 @@ impl IndexScheduler { #[cfg(test)] self.maybe_fail(tests::FailureLocation::AcquiringWtxn)?; + processing_batch.finished(); let mut wtxn = self.env.write_txn().map_err(Error::HeedTransaction)?; - let finished_at = OffsetDateTime::now_utc(); match res { Ok(tasks) => { #[cfg(test)] @@ -1602,14 +1602,10 @@ impl IndexScheduler { let mut canceled_by = None; let mut canceled = RoaringBitmap::new(); - dbg!(&tasks); - #[allow(unused_variables)] for (i, mut task) in tasks.into_iter().enumerate() { - if task.status != Status::Canceled { - task.started_at = Some(processing_batch.started_at); - task.finished_at = Some(finished_at); - } else { + processing_batch.update(&mut task); + if task.status == Status::Canceled { canceled.insert(task.uid); canceled_by = task.canceled_by; } @@ -1628,10 +1624,8 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; - processing_batch.update(&task); } if let Some(canceled_by) = canceled_by { - println!("inserting the canceled by {canceled_by}: {canceled:?}"); self.canceled_by.put(&mut wtxn, &canceled_by, &canceled)?; } tracing::info!("A batch of tasks was successfully completed with {success} successful tasks and {failure} failed tasks."); @@ -1681,12 +1675,10 @@ impl IndexScheduler { .get_task(&wtxn, id) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))? .ok_or(Error::CorruptedTaskQueue)?; - task.batch_uid = Some(processing_batch.uid); - task.started_at = Some(processing_batch.started_at); - task.finished_at = Some(finished_at); task.status = Status::Failed; task.error = Some(error.clone()); task.details = task.details.map(|d| d.to_failed()); + processing_batch.update(&mut task); #[cfg(test)] self.maybe_fail(tests::FailureLocation::UpdatingTaskAfterProcessBatchFailure)?; @@ -1695,14 +1687,13 @@ impl IndexScheduler { self.update_task(&mut wtxn, &task) .map_err(|e| Error::TaskDatabaseUpdate(Box::new(e)))?; - processing_batch.update(&task); } } } let processed = self.processing_tasks.write().unwrap().stop_processing(); - self.write_batch(&mut wtxn, processing_batch, &processed.processing, finished_at)?; + self.write_batch(&mut wtxn, processing_batch, &processed.processing)?; #[cfg(test)] self.maybe_fail(tests::FailureLocation::CommittingWtxn)?; diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap index 82bb48bc4..fa67aa779 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap @@ -34,19 +34,20 @@ catto [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Started At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"documentAdditionOrUpdate":1,"taskCancelation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] +canceled [0,] ---------------------------------------------------------------------- ### Batches Kind: "documentAdditionOrUpdate" [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap index ef4c72d06..345ac39a6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/aborted_indexation.snap @@ -46,7 +46,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap index de85afb77..d94494a26 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap @@ -43,15 +43,15 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ---------------------------------------------------------------------- ### Started At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### Finished At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":2,"indexedDocuments":0,"matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query"}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"receivedDocuments":2,"indexedDocuments":0,"matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query"}, stats: {"totalNbTasks":3,"status":{"succeeded":1,"canceled":2},"types":{"documentAdditionOrUpdate":2,"taskCancelation":1},"indexUids":{"beavero":1,"wolfo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] @@ -59,6 +59,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] +canceled [1,] ---------------------------------------------------------------------- ### Batches Kind: "documentAdditionOrUpdate" [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap index 96905e096..17265263c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/first_task_processed.snap @@ -42,7 +42,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap index f56849774..5d1cfb61e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/processing_second_task_cancel_enqueued.snap @@ -45,7 +45,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap index b81db3316..670116fe1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap @@ -33,19 +33,20 @@ canceled [0,] [timestamp] [1,] ---------------------------------------------------------------------- ### Started At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"matchedTasks":1,"canceledTasks":1,"originalFilter":"cancel dump"}, } +0 {uid: 0, details: {"matchedTasks":1,"canceledTasks":1,"originalFilter":"cancel dump"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"taskCancelation":1,"dumpCreation":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] +canceled [0,] ---------------------------------------------------------------------- ### Batches Kind: "taskCancelation" [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap index bf206e539..ece94e06a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap @@ -35,19 +35,20 @@ catto: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### Started At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### Finished At: -[timestamp] [1,] +[timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"documentAdditionOrUpdate":1,"taskCancelation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] +canceled [0,] ---------------------------------------------------------------------- ### Batches Kind: "documentAdditionOrUpdate" [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap index 8f141b214..de94da936 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/cancel_processed.snap @@ -41,8 +41,8 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"matchedTasks":1,"canceledTasks":0,"originalFilter":"test_query"}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"matchedTasks":1,"canceledTasks":0,"originalFilter":"test_query"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"taskCancelation":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap index 9f2fac934..78b62979b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_succeeded_task/initial_task_processed.snap @@ -36,7 +36,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap index c903fef85..3fe1a7d01 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/do_not_batch_task_of_different_indexes/all_tasks_processed.snap @@ -61,12 +61,12 @@ girafos: { number_of_documents: 0, field_distribution: {} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {}, } -3 {uid: 3, details: {"deletedDocuments":0}, } -4 {uid: 4, details: {"deletedDocuments":0}, } -5 {uid: 5, details: {"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"cattos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"girafos":1}}, } +3 {uid: 3, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"cattos":1}}, } +5 {uid: 5, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"girafos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap index 87e4bc88d..2357a404f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition/once_everything_is_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap index 19dc4103e..1fce684f5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_document_deletion/after_processing_the_batch.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":3,"indexedDocuments":3,"providedIds":2,"deletedDocuments":2}, } +0 {uid: 0, details: {"receivedDocuments":3,"indexedDocuments":3,"providedIds":2,"deletedDocuments":2}, stats: {"totalNbTasks":2,"status":{"succeeded":2},"types":{"documentAdditionOrUpdate":1,"documentDeletion":1},"indexUids":{"doggos":2}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap index 770a22457..0234a5057 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/before_index_creation.snap @@ -42,7 +42,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap index b6c38da20..8203e81f4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion/both_task_succeeded.snap @@ -43,8 +43,8 @@ doggos [0,1,2,] [timestamp] [1,2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, stats: {"totalNbTasks":2,"status":{"succeeded":2},"types":{"documentAdditionOrUpdate":1,"indexDeletion":1},"indexUids":{"doggos":2}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap index d26ed4124..830afd854 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_addition_and_index_deletion_on_unexisting_index/2.snap @@ -38,7 +38,7 @@ doggos [0,1,] [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"deletedDocuments":0}, stats: {"totalNbTasks":2,"status":{"succeeded":2},"types":{"documentAdditionOrUpdate":1,"indexDeletion":1},"indexUids":{"doggos":2}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 891f77b63..1bf5ce7ba 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -38,7 +38,7 @@ doggos [0,1,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index 1138c5e03..27b10199d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -42,8 +42,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index 741a02636..f73c480bc 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -35,7 +35,7 @@ doggos [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap index 3201eff58..8d175e388 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_documents.snap @@ -41,8 +41,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"filterableAttributes":["catto"]}, } -1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap index d7adfdc46..d1de7ec61 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_adding_the_settings.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"filterableAttributes":["catto"]}, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index 226fde294..ca5470c5e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -53,9 +53,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"filterableAttributes":["catto"]}, } -1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } -2 {uid: 2, details: {"providedIds":1,"deletedDocuments":2,"originalFilter":"\"catto EXISTS\""}, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"providedIds":1,"deletedDocuments":2,"originalFilter":"\"catto EXISTS\""}, stats: {"totalNbTasks":4,"status":{"succeeded":2,"failed":2},"types":{"documentDeletion":4},"indexUids":{"doggos":4}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] @@ -64,6 +64,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,2,] +failed [2,] ---------------------------------------------------------------------- ### Batches Kind: "documentAdditionOrUpdate" [1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap index 68058b616..b2b368be4 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/registered_the_document_deletions.snap @@ -50,8 +50,8 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"filterableAttributes":["catto"]}, } -1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, } +0 {uid: 0, details: {"filterableAttributes":["catto"]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 845de58de..4cc7ad154 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap index 87e4bc88d..2357a404f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_update_task_after_process_batch_success_for_document_addition/task_successfully_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap index 4b7c1a1f9..efeaac93f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir succeeds.snap @@ -45,9 +45,9 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap index 9ee0447d6..4851b99c9 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/Intel to kefir.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap index be04ea541..540fd4860 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/adding Intel succeeds.snap @@ -41,8 +41,8 @@ doggos: { number_of_documents: 1, field_distribution: {"_vectors": 1, "breed": 1 [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap index 2229139d7..c8f174c74 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/after adding Intel.snap @@ -39,7 +39,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap index a9e162b9c..24d5fff27 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/import_vectors/settings_update_processed_vectors.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, } +0 {uid: 0, details: {"embedders":{"A_fakerest":{"source":"rest","apiKey":"MyXXXX...","dimensions":384,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"},"B_small_hf":{"source":"huggingFace","model":"sentence-transformers/all-MiniLM-L6-v2","revision":"e4ce9877abf3edfe10b0d82785e83bdcb973e22e","documentTemplate":"{{doc.doggo}} the {{doc.breed}} best doggo"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index 52bcfe6f6..7d1875617 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap index 6a5b847e9..8d499b59c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_first_task.snap @@ -42,7 +42,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap index 8b4b88a8d..423dfb37c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_second_task.snap @@ -45,8 +45,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"cattos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap index 19c9957ed..e5878246d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_inserted_without_new_signal/processed_the_third_task.snap @@ -46,9 +46,9 @@ cattos: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"cattos":1}}, } +2 {uid: 2, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap index 6762b0707..ac18e924d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/first.snap @@ -43,7 +43,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap index 9fdb5aceb..06e63e00e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/fourth.snap @@ -49,10 +49,10 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"deletedDocuments":0}, } -2 {uid: 2, details: {"deletedDocuments":0}, } -3 {uid: 3, details: {"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap index b7d505301..632b7a54a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/second.snap @@ -45,8 +45,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap index aaa714bde..3a2963654 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/process_tasks_without_autobatching/third.snap @@ -47,9 +47,9 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"deletedDocuments":0}, } -2 {uid: 2, details: {"deletedDocuments":0}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap index a48246ae6..79c5e6499 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap @@ -42,15 +42,15 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Started At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### Finished At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"mouse"}, } -1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, stats: {"totalNbTasks":3,"status":{"succeeded":1,"canceled":2},"types":{"indexCreation":1,"indexSwap":1,"taskCancelation":1},"indexUids":{"doggo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] @@ -58,6 +58,7 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] +canceled [1,] ---------------------------------------------------------------------- ### Batches Kind: "indexCreation" [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap index ebb20f2e7..9f5c7e4ad 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_from_and_limit/processed_all_tasks.snap @@ -48,9 +48,9 @@ whalo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"bone"}, } -1 {uid: 1, details: {"primaryKey":"plankton"}, } -2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, } +0 {uid: 0, details: {"primaryKey":"bone"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } +1 {uid: 1, details: {"primaryKey":"plankton"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } +2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap index bbe89cf36..b99e7740b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap @@ -48,9 +48,9 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"mouse"}, } -1 {uid: 1, details: {"primaryKey":"sheep"}, } -2 {uid: 2, details: {}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap index 2783c3049..982db13a0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap @@ -53,10 +53,10 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"mouse"}, } -1 {uid: 1, details: {"primaryKey":"sheep"}, } -2 {uid: 2, details: {}, } -3 {uid: 3, details: {}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } +3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap index a48246ae6..79c5e6499 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap @@ -42,15 +42,15 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Started At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### Finished At: [timestamp] [0,] -[timestamp] [3,] +[timestamp] [1,2,3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"mouse"}, } -1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"primaryKey":"sheep","matchedTasks":3,"canceledTasks":2,"originalFilter":"test_query","swaps":[{"indexes":["catto","doggo"]}]}, stats: {"totalNbTasks":3,"status":{"succeeded":1,"canceled":2},"types":{"indexCreation":1,"indexSwap":1,"taskCancelation":1},"indexUids":{"doggo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] @@ -58,6 +58,7 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] +canceled [1,] ---------------------------------------------------------------------- ### Batches Kind: "indexCreation" [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap index ebb20f2e7..9f5c7e4ad 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_from_and_limit/processed_all_tasks.snap @@ -48,9 +48,9 @@ whalo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"bone"}, } -1 {uid: 1, details: {"primaryKey":"plankton"}, } -2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, } +0 {uid: 0, details: {"primaryKey":"bone"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } +1 {uid: 1, details: {"primaryKey":"plankton"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } +2 {uid: 2, details: {"primaryKey":"his_own_vomit"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index bbe89cf36..b99e7740b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -48,9 +48,9 @@ doggo: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"mouse"}, } -1 {uid: 1, details: {"primaryKey":"sheep"}, } -2 {uid: 2, details: {}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap index 84566cd49..b1c6fde36 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_a.snap @@ -45,7 +45,7 @@ a: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap index a5581d589..065023214 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_b.snap @@ -48,8 +48,8 @@ b: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap index 9ad7e5505..03b09b928 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_c.snap @@ -51,9 +51,9 @@ c: { number_of_documents: 0, field_distribution: {} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap index cd578260c..08ecfddc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/create_d.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap index dd31bb637..bca858559 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_processed.snap @@ -61,11 +61,11 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } -4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap index 74fc1b4f5..234915267 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/first_swap_registered.snap @@ -57,10 +57,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap index 792707b06..7b5ab6e4b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/second_swap_processed.snap @@ -63,12 +63,12 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } -4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } -5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } +5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap index 342797b32..77b1193a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/third_empty_swap_processed.snap @@ -67,13 +67,13 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [6,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } -4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, } -5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, } -6 {uid: 6, details: {"swaps":[]}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","d"]}]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } +5 {uid: 5, details: {"swaps":[{"indexes":["a","c"]}]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } +6 {uid: 6, details: {"swaps":[]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap index 15cb92534..ccab86904 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes/two_swaps_registered.snap @@ -59,10 +59,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap index cd578260c..08ecfddc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/after_the_index_creation.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index 148f95abb..4d2f86df2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -62,11 +62,11 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } -4 {uid: 4, details: {}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } +4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap index cd578260c..08ecfddc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/initial_tasks_processed.snap @@ -54,10 +54,10 @@ d: { number_of_documents: 0, field_distribution: {} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"primaryKey":"id"}, } -1 {uid: 1, details: {"primaryKey":"id"}, } -2 {uid: 2, details: {"primaryKey":"id"}, } -3 {uid: 3, details: {"primaryKey":"id"}, } +0 {uid: 0, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"a":1}}, } +1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } +2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } +3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap index 671c4c16e..f63c498a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/initial_tasks_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap index 8ab24e82a..95d615b1e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_delete_same_task_twice/task_deletion_processed.snap @@ -41,7 +41,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,3,] ---------------------------------------------------------------------- ### All Batches: -1 {uid: 1, details: {"matchedTasks":2,"deletedTasks":1,"originalFilter":"test_query&test_query"}, } +1 {uid: 1, details: {"matchedTasks":2,"deletedTasks":1,"originalFilter":"test_query&test_query"}, stats: {"totalNbTasks":2,"status":{"succeeded":2},"types":{"taskDeletion":2},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 1 [2,3,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap index ff0c65910..6402982ee 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/after_registering_the_task_deletion.snap @@ -42,7 +42,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap index 671c4c16e..f63c498a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/initial_tasks_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap index 570a8e517..3f4ae56d8 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_deleteable/task_deletion_processed.snap @@ -39,7 +39,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -1 {uid: 1, details: {"matchedTasks":1,"deletedTasks":1,"originalFilter":"test_query"}, } +1 {uid: 1, details: {"matchedTasks":1,"deletedTasks":1,"originalFilter":"test_query"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"taskDeletion":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 1 [2,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap index de7430ddb..ae910d44b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/task_deletion_undeleteable/task_deletion_done.snap @@ -44,7 +44,7 @@ doggo [2,] [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"matchedTasks":2,"deletedTasks":0,"originalFilter":"test_query"}, } +0 {uid: 0, details: {"matchedTasks":2,"deletedTasks":0,"originalFilter":"test_query"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"taskDeletion":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [3,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap index eaf694e4a..5efac0653 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_processing_the_10_tasks.snap @@ -59,8 +59,8 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, stats: {"totalNbTasks":10,"status":{"succeeded":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap index 7aee46969..cdc1f98b7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap index 5399443a9..24ace66bf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap index 2c5305088..f937c6805 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap index 766d2624a..28a2a65a5 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/all_tasks_processed.snap @@ -77,17 +77,17 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } -5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } -6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } -7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } -8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } -9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } -10 {uid: 10, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +10 {uid: 10, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap index 7bc408a14..519646fcb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/five_tasks_processed.snap @@ -67,12 +67,12 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } -5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap index 6d9343ce5..f842a275e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_with_index_without_autobatching/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index 3a6a394dc..6e1f526c0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":10,"status":{"failed":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index d95d8f8db..95d454011 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -71,16 +71,16 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {}, } -3 {uid: 3, details: {}, } -4 {uid: 4, details: {}, } -5 {uid: 5, details: {}, } -6 {uid: 6, details: {}, } -7 {uid: 7, details: {}, } -8 {uid: 8, details: {}, } -9 {uid: 9, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index c8e2fd93b..7dbd40e0d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -61,11 +61,11 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {}, } -3 {uid: 3, details: {}, } -4 {uid: 4, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index 700044b79..2c7faa488 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -57,8 +57,8 @@ doggos: { number_of_documents: 9, field_distribution: {"doggo": 9, "id": 9} } [timestamp] [1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":9,"indexedDocuments":9}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":9,"indexedDocuments":9}, stats: {"totalNbTasks":9,"status":{"succeeded":9},"types":{"documentAdditionOrUpdate":9},"indexUids":{"doggos":9}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index e08954bca..18a971baa 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap index 78058a92d..00c911dae 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/after_registering_the_10_tasks.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap index 68113fc86..99922b9a0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/all_tasks_processed.snap @@ -59,8 +59,8 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [1,2,3,4,5,6,7,8,9,10,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":10,"indexedDocuments":10}, stats: {"totalNbTasks":10,"status":{"succeeded":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap index 5399443a9..24ace66bf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_rights_with_index/processed_the_first_task.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index 281bdd96a..477520a14 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -51,10 +51,10 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "id": 2} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index 0a2ff55b1..1d3281384 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -44,7 +44,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 74353f21b..5cf144edd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -49,9 +49,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index 1d7c61d91..7adc83fd3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -47,8 +47,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap index f01d8adf3..f12ac555b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/only_first_task_succeed.snap @@ -40,7 +40,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index 5948f1c90..b7098b60a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index 87b14c7be..63c1b5f89 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -45,9 +45,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap index e94d544bb..d01799fc2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/only_first_task_succeed.snap @@ -40,7 +40,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 6c3c13305..52391905d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -43,8 +43,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index 2cf46c611..526407329 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -53,10 +53,10 @@ doggos: { number_of_documents: 4, field_distribution: {"doggo": 4, "paw": 4} } [timestamp] [3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":3,"status":{"succeeded":3},"types":{"documentAdditionOrUpdate":3},"indexUids":{"doggos":3}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index 4d8f1fad9..41517d90b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -46,7 +46,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index 3ee347076..a46f9078d 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -48,8 +48,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index 13f20f31b..0f6c32310 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -51,9 +51,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "paw": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index dd91d7c5d..0b294a0d1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -53,10 +53,10 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "doggoid": 5} [timestamp] [3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":3,"status":{"succeeded":3},"types":{"documentAdditionOrUpdate":3},"indexUids":{"doggos":3}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap index 525c83371..4acc5342b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/first_task_succeed.snap @@ -46,7 +46,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index 6ba811363..5c78a6550 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -49,8 +49,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index a397c7fdd..6baa913fe 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -51,9 +51,9 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "doggoid": 2} [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap index 277bc8aff..d2cfc793b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace/2.snap @@ -54,7 +54,7 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, } +0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, stats: {"totalNbTasks":10,"status":{"succeeded":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap index 4b4ace120..5c6c711a0 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } -5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } -6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } -7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } -8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } -9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap index bea6f75ce..e03da1332 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_replace_without_autobatching/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap index b98540594..9e742df7b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update/2.snap @@ -54,7 +54,7 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, } +0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":10}, stats: {"totalNbTasks":10,"status":{"succeeded":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap index d30a8b0c2..ef6e2d0e1 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } -5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } -6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } -7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } -8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } -9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap index 0b608c691..bfc2e9f42 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_update_without_autobatching/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap index 8324b62ae..a4649c1eb 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/all_tasks_processed.snap @@ -72,16 +72,16 @@ doggos: { number_of_documents: 10, field_distribution: {"doggo": 10, "id": 10} } [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } -5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, } -6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, } -7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, } -8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, } -9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap index f2a03bcab..8aba4bd5c 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_mixed_document_addition/five_tasks_processed.snap @@ -62,11 +62,11 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "id": 5} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, } -1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, } -2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, } -3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, } -4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap index bea2d5ab1..dae9b38cd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_settings_update/settings_update_processed.snap @@ -36,7 +36,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {"embedders":{"default":{"source":"rest","apiKey":"MyXXXX...","dimensions":4,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"}}}, } +0 {uid: 0, details: {"embedders":{"default":{"source":"rest","apiKey":"MyXXXX...","dimensions":4,"url":"http://localhost:7777","request":"{{text}}","response":"{{embedding}}"}}}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 322d15ea9..6311359b3 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -3,7 +3,7 @@ use std::collections::{BTreeSet, HashSet}; use std::ops::Bound; -use meilisearch_types::batches::{Batch, BatchId}; +use meilisearch_types::batches::{Batch, BatchId, BatchStats}; use meilisearch_types::heed::types::DecodeIgnore; use meilisearch_types::heed::{Database, RoTxn, RwTxn}; use meilisearch_types::milli::CboRoaringBitmapCodec; @@ -16,10 +16,16 @@ use crate::{Error, IndexScheduler, Result, Task, TaskId, BEI128}; /// This structure contains all the information required to write a batch in the database without reading the tasks. /// It'll stay in RAM so it must be small. +/// The usage is the following: +/// 1. Create the structure with its batch id. +/// 2. Call `processing` on all the task that we know are currently processing in the batch (it can change in the future) +/// 3. Call `finished` once the batch has been processed. +/// 4. Call `update` on all the tasks. #[derive(Debug, Clone)] pub(crate) struct ProcessingBatch { pub uid: BatchId, pub details: DetailsView, + pub stats: BatchStats, pub statuses: HashSet, pub kinds: HashSet, @@ -28,6 +34,7 @@ pub(crate) struct ProcessingBatch { pub oldest_enqueued_at: Option, pub earliest_enqueued_at: Option, pub started_at: OffsetDateTime, + pub finished_at: Option, } impl ProcessingBatch { @@ -39,6 +46,7 @@ impl ProcessingBatch { Self { uid, details: DetailsView::default(), + stats: BatchStats::default(), statuses, kinds: HashSet::default(), @@ -47,21 +55,10 @@ impl ProcessingBatch { oldest_enqueued_at: None, earliest_enqueued_at: None, started_at: OffsetDateTime::now_utc(), + finished_at: None, } } - /// Remove the Processing status and update the real statuses of the tasks. - pub fn update(&mut self, task: &Task) { - // Craft an aggregation of the details of all the tasks encountered in this batch. - if task.status != Status::Failed { - if let Some(ref details) = task.details { - self.details.accumulate(&DetailsView::from(details.clone())); - } - } - self.statuses.clear(); - self.statuses.insert(task.status); - } - /// 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) { for task in tasks.into_iter() { @@ -82,6 +79,45 @@ impl ProcessingBatch { })); } } + + /// Must be called once the batch has finished processing. + pub fn finished(&mut self) { + self.finished_at = Some(OffsetDateTime::now_utc()); + + // Initially we inserted ourselves as a processing batch, that's not the case anymore. + self.statuses.clear(); + + // We're going to recount the number of tasks AFTER processing the batch because + // tasks may add themselves to a batch while its processing. + self.stats.total_nb_tasks = 0; + } + + /// Update the timestamp of the tasks and the inner structure of this sturcture. + pub fn update(&mut self, task: &mut Task) { + // We must re-set this value in case we're dealing with a task that has been added between + // the `processing` and `finished` state + // We must re-set this value in case we're dealing with a task that has been added between + // the `processing` and `finished` state or that failed. + task.batch_uid = Some(self.uid); + // Same + task.started_at = Some(self.started_at); + task.finished_at = self.finished_at; + + self.statuses.insert(task.status); + + // Craft an aggregation of the details of all the tasks encountered in this batch. + if task.status != Status::Failed { + if let Some(ref details) = task.details { + self.details.accumulate(&DetailsView::from(details.clone())); + } + } + self.stats.total_nb_tasks += 1; + *self.stats.status.entry(task.status).or_default() += 1; + *self.stats.types.entry(task.kind.as_kind()).or_default() += 1; + if let Some(index_uid) = task.index_uid() { + *self.stats.index_uids.entry(index_uid.to_string()).or_default() += 1; + } + } } impl IndexScheduler { @@ -123,7 +159,6 @@ impl IndexScheduler { wtxn: &mut RwTxn, batch: ProcessingBatch, tasks: &RoaringBitmap, - finished_at: OffsetDateTime, ) -> Result<()> { self.all_batches.put( wtxn, @@ -131,8 +166,9 @@ impl IndexScheduler { &Batch { uid: batch.uid, details: batch.details, + stats: batch.stats, started_at: batch.started_at, - finished_at: Some(finished_at), + finished_at: batch.finished_at, }, )?; self.batch_to_tasks_mapping.put(wtxn, &batch.uid, tasks)?; @@ -162,7 +198,7 @@ impl IndexScheduler { insert_task_datetime(wtxn, self.batch_enqueued_at, enqueued_at, batch.uid)?; } insert_task_datetime(wtxn, self.batch_started_at, batch.started_at, batch.uid)?; - insert_task_datetime(wtxn, self.batch_finished_at, finished_at, batch.uid)?; + insert_task_datetime(wtxn, self.batch_finished_at, batch.finished_at.unwrap(), batch.uid)?; Ok(()) } diff --git a/crates/meilisearch-types/src/batch_view.rs b/crates/meilisearch-types/src/batch_view.rs index 684fc48e6..5d800d897 100644 --- a/crates/meilisearch-types/src/batch_view.rs +++ b/crates/meilisearch-types/src/batch_view.rs @@ -2,16 +2,17 @@ use serde::Serialize; use time::{Duration, OffsetDateTime}; use crate::{ - batches::{Batch, BatchId}, + batches::{Batch, BatchId, BatchStats}, task_view::DetailsView, tasks::serialize_duration, }; -#[derive(Debug, Clone, PartialEq, Eq, Serialize)] +#[derive(Debug, Clone, Serialize)] #[serde(rename_all = "camelCase")] pub struct BatchView { pub uid: BatchId, pub details: DetailsView, + pub stats: BatchStats, #[serde(serialize_with = "serialize_duration", default)] pub duration: Option, #[serde(with = "time::serde::rfc3339", default)] @@ -25,6 +26,7 @@ impl BatchView { Self { uid: batch.uid, details: batch.details.clone(), + stats: batch.stats.clone(), duration: batch.finished_at.map(|finished_at| finished_at - batch.started_at), started_at: batch.started_at, finished_at: batch.finished_at, diff --git a/crates/meilisearch-types/src/batches.rs b/crates/meilisearch-types/src/batches.rs index c5c4530ec..a60386e52 100644 --- a/crates/meilisearch-types/src/batches.rs +++ b/crates/meilisearch-types/src/batches.rs @@ -1,22 +1,34 @@ +use std::collections::BTreeMap; + use serde::{Deserialize, Serialize}; use time::OffsetDateTime; -use crate::task_view::DetailsView; +use crate::{ + task_view::DetailsView, + tasks::{Kind, Status}, +}; pub type BatchId = u32; -#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)] +#[derive(Clone, Debug, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Batch { pub uid: BatchId, pub details: DetailsView, + pub stats: BatchStats, #[serde(with = "time::serde::rfc3339")] pub started_at: OffsetDateTime, #[serde(with = "time::serde::rfc3339::option")] pub finished_at: Option, - // pub details: Option
, - - // pub status: Status, +} + +#[derive(Default, Debug, Clone, Serialize, Deserialize)] +#[serde(rename_all = "camelCase")] +pub struct BatchStats { + pub total_nb_tasks: BatchId, + pub status: BTreeMap, + pub types: BTreeMap, + pub index_uids: BTreeMap, } diff --git a/crates/meilisearch-types/src/tasks.rs b/crates/meilisearch-types/src/tasks.rs index f5875225a..c62f550ae 100644 --- a/crates/meilisearch-types/src/tasks.rs +++ b/crates/meilisearch-types/src/tasks.rs @@ -363,7 +363,9 @@ impl From<&KindWithContent> for Option
{ } } -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, Sequence)] +#[derive( + Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, Sequence, PartialOrd, Ord, +)] #[serde(rename_all = "camelCase")] pub enum Status { Enqueued, @@ -422,7 +424,9 @@ impl fmt::Display for ParseTaskStatusError { } impl std::error::Error for ParseTaskStatusError {} -#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, Sequence)] +#[derive( + Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, Sequence, PartialOrd, Ord, +)] #[serde(rename_all = "camelCase")] pub enum Kind { DocumentAdditionOrUpdate, diff --git a/crates/meilisearch/tests/batches/mod.rs b/crates/meilisearch/tests/batches/mod.rs index 48fbc34e3..f04c7042e 100644 --- a/crates/meilisearch/tests/batches/mod.rs +++ b/crates/meilisearch/tests/batches/mod.rs @@ -296,6 +296,22 @@ async fn test_summarized_document_addition_or_update() { @r#" { "uid": 0, + "details": { + "receivedDocuments": 1, + "indexedDocuments": 1 + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "documentAdditionOrUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -310,6 +326,22 @@ async fn test_summarized_document_addition_or_update() { @r#" { "uid": 1, + "details": { + "receivedDocuments": 1, + "indexedDocuments": 1 + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "documentAdditionOrUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -329,6 +361,19 @@ async fn test_summarized_delete_documents_by_batch() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -344,6 +389,22 @@ async fn test_summarized_delete_documents_by_batch() { @r#" { "uid": 2, + "details": { + "providedIds": 1, + "deletedDocuments": 0 + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -364,6 +425,19 @@ async fn test_summarized_delete_documents_by_filter() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -379,6 +453,19 @@ async fn test_summarized_delete_documents_by_filter() { @r#" { "uid": 2, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -394,6 +481,23 @@ async fn test_summarized_delete_documents_by_filter() { @r#" { "uid": 4, + "details": { + "providedIds": 0, + "deletedDocuments": 0, + "originalFilter": "\"doggo = bernese\"" + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -413,6 +517,19 @@ async fn test_summarized_delete_document_by_id() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -428,6 +545,22 @@ async fn test_summarized_delete_document_by_id() { @r#" { "uid": 2, + "details": { + "providedIds": 1, + "deletedDocuments": 0 + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "documentDeletion": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -459,6 +592,31 @@ async fn test_summarized_settings_update() { @r#" { "uid": 0, + "details": { + "displayedAttributes": [ + "doggos", + "name" + ], + "filterableAttributes": [ + "age", + "nb_paw_pads" + ], + "sortableAttributes": [ + "iq" + ] + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "settingsUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -478,6 +636,19 @@ async fn test_summarized_index_creation() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "indexCreation": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -492,6 +663,19 @@ async fn test_summarized_index_creation() { @r#" { "uid": 1, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "indexCreation": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -621,6 +805,19 @@ async fn test_summarized_index_update() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "indexUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -635,6 +832,19 @@ async fn test_summarized_index_update() { @r#" { "uid": 1, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "indexUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -652,6 +862,19 @@ async fn test_summarized_index_update() { @r#" { "uid": 3, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "indexUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -666,6 +889,21 @@ async fn test_summarized_index_update() { @r#" { "uid": 4, + "details": { + "primaryKey": "bones" + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "indexUpdate": 1 + }, + "indexUids": { + "test": 1 + } + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -688,6 +926,17 @@ async fn test_summarized_index_swap() { @r#" { "uid": 0, + "details": {}, + "stats": { + "totalNbTasks": 1, + "status": { + "failed": 1 + }, + "types": { + "indexSwap": 1 + }, + "indexUids": {} + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -708,6 +957,26 @@ async fn test_summarized_index_swap() { @r#" { "uid": 3, + "details": { + "swaps": [ + { + "indexes": [ + "doggos", + "cattos" + ] + } + ] + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "indexSwap": 1 + }, + "indexUids": {} + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -730,6 +999,21 @@ async fn test_summarized_batch_cancelation() { @r#" { "uid": 1, + "details": { + "matchedTasks": 1, + "canceledTasks": 0, + "originalFilter": "?uids=0" + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "taskCancelation": 1 + }, + "indexUids": {} + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -752,6 +1036,21 @@ async fn test_summarized_batch_deletion() { @r#" { "uid": 1, + "details": { + "matchedTasks": 1, + "deletedTasks": 1, + "originalFilter": "?uids=0" + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "taskDeletion": 1 + }, + "indexUids": {} + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" @@ -770,6 +1069,19 @@ async fn test_summarized_dump_creation() { @r#" { "uid": 0, + "details": { + "dumpUid": "[dumpUid]" + }, + "stats": { + "totalNbTasks": 1, + "status": { + "succeeded": 1 + }, + "types": { + "dumpCreation": 1 + }, + "indexUids": {} + }, "duration": "[duration]", "startedAt": "[date]", "finishedAt": "[date]" From b906e3ed708a5b34bce9d0ca85c44a6c39674fcf Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 19:40:31 +0100 Subject: [PATCH 12/22] improve the way we access the mutex --- crates/index-scheduler/src/error.rs | 2 +- crates/index-scheduler/src/lib.rs | 81 ++++++++------ .../after_failing_the_deletion.snap | 2 +- .../after_last_successful_addition.snap | 2 +- .../document_addition_failed.snap | 2 +- .../after_removing_the_documents.snap | 2 +- .../index_creation_failed.snap | 2 +- .../index_creation_failed.snap | 2 +- .../lib.rs/query_batches_simple/end.snap | 2 +- .../after-processing-everything.snap | 4 +- .../lib.rs/query_tasks_simple/end.snap | 2 +- .../first_swap_failed.snap | 2 +- .../after_processing_the_10_tasks.snap | 2 +- .../all_tasks_processed.snap | 20 ++-- .../five_tasks_processed.snap | 10 +- .../all_tasks_processed.snap | 2 +- .../only_first_task_failed.snap | 2 +- .../fifth_task_succeeds.snap | 4 +- .../first_and_second_task_fails.snap | 2 +- .../fourth_task_fails.snap | 4 +- .../third_task_succeeds.snap | 2 +- .../second_task_fails.snap | 2 +- .../third_task_fails.snap | 4 +- .../second_and_third_tasks_fails.snap | 2 +- .../all_other_tasks_succeeds.snap | 4 +- .../first_task_fails.snap | 2 +- .../second_task_fails.snap | 4 +- .../third_task_succeeds.snap | 4 +- .../all_other_tasks_succeeds.snap | 2 +- .../second_task_fails.snap | 2 +- .../third_task_succeeds.snap | 2 +- crates/index-scheduler/src/utils.rs | 27 +++-- crates/meilisearch/src/routes/batches.rs | 2 +- crates/meilisearch/tests/batches/mod.rs | 100 +++++++----------- 34 files changed, 155 insertions(+), 155 deletions(-) diff --git a/crates/index-scheduler/src/error.rs b/crates/index-scheduler/src/error.rs index 336c0b732..f6a4ecc04 100644 --- a/crates/index-scheduler/src/error.rs +++ b/crates/index-scheduler/src/error.rs @@ -230,7 +230,7 @@ impl ErrorCode for Error { Error::InvalidTaskCanceledBy { .. } => Code::InvalidTaskCanceledBy, Error::InvalidIndexUid { .. } => Code::InvalidIndexUid, Error::TaskNotFound(_) => Code::TaskNotFound, - Error::BatchNotFound(_) => Code::TaskNotFound, + Error::BatchNotFound(_) => Code::BatchNotFound, Error::TaskDeletionWithEmptyQuery => Code::MissingTaskFilters, Error::TaskCancelationWithEmptyQuery => Code::MissingTaskFilters, // TODO: not sure of the Code to use diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index f66f147e2..9541e9736 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -163,7 +163,7 @@ impl Query { } #[derive(Debug, Clone)] -struct ProcessingTasks { +pub struct ProcessingTasks { batch: Option, /// The list of tasks ids that are currently running. processing: RoaringBitmap, @@ -948,6 +948,7 @@ impl IndexScheduler { processing: &ProcessingTasks, query: &Query, ) -> Result { + dbg!(); let mut batches = self.all_batch_ids(rtxn)?; if let Some(batch_id) = processing.batch.as_ref().map(|batch| batch.uid) { batches.insert(batch_id); @@ -1235,22 +1236,21 @@ impl IndexScheduler { /// 1. IndexSwap tasks are not publicly associated with any index, but they are associated /// with many indexes internally. /// 2. The user may not have the rights to access the tasks (internally) associated with all indexes. - pub fn get_batch_ids_from_authorized_indexes( + fn get_batch_ids_from_authorized_indexes( &self, rtxn: &RoTxn, + processing: &ProcessingTasks, query: &Query, filters: &meilisearch_auth::AuthFilter, ) -> Result<(RoaringBitmap, u64)> { - let processing = self.processing_tasks.read().unwrap().clone(); - // compute all batches matching the filter by ignoring the limits, to find the number of batches matching // the filter. // As this causes us to compute the filter twice it is slightly inefficient, but doing it this way spares // us from modifying the underlying implementation, and the performance remains sufficient. // Should this change, we would modify `get_batch_ids` to directly return the number of matching batches. let total_batches = - self.get_batch_ids(rtxn, &processing, &query.clone().without_limits())?; - let mut batches = self.get_batch_ids(rtxn, &processing, query)?; + self.get_batch_ids(rtxn, processing, &query.clone().without_limits())?; + let mut batches = self.get_batch_ids(rtxn, processing, query)?; // If the query contains a list of index uid or there is a finite list of authorized indexes, // then we must exclude all the batches that only contains tasks associated to multiple indexes. @@ -1369,11 +1369,14 @@ impl IndexScheduler { filters: &meilisearch_auth::AuthFilter, ) -> Result<(Vec, u64)> { let rtxn = self.env.read_txn()?; + let processing = self.processing_tasks.read().unwrap().clone(); let (batches, total) = - self.get_batch_ids_from_authorized_indexes(&rtxn, &query, filters)?; + self.get_batch_ids_from_authorized_indexes(&rtxn, &processing, &query, filters)?; + let batches = self.get_existing_batches( &rtxn, + &processing, batches.into_iter().rev().take(query.limit.unwrap_or(u32::MAX) as usize), )?; @@ -4202,46 +4205,47 @@ mod tests { handle.advance_n_successful_batches(3); snapshot!(snapshot_index_scheduler(&index_scheduler), name: "processed_all_tasks"); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let rtxn = index_scheduler.env.read_txn().unwrap(); let query = Query { limit: Some(0), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[]"); let query = Query { limit: Some(1), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[2,]"); let query = Query { limit: Some(2), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[1,2,]"); let query = Query { from: Some(1), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); let query = Query { from: Some(2), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[0,1,2,]"); let query = Query { from: Some(1), limit: Some(1), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[1,]"); let query = Query { from: Some(1), limit: Some(2), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[0,1,]"); } @@ -4265,16 +4269,17 @@ mod tests { handle.advance_till([Start, BatchCreated]); let rtxn = index_scheduler.env.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let query = Query { statuses: Some(vec![Status::Processing]), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[0,]"); // only the processing batch in the first tick let query = Query { statuses: Some(vec![Status::Enqueued]), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[]"); // The batches don't contains any enqueued tasks @@ -4283,7 +4288,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); snapshot!(snapshot_bitmap(&batches), @"[0,]"); // both enqueued and processing tasks in the first tick @@ -4293,7 +4298,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both enqueued and processing tasks in the first tick, but limited to those with a started_at // that comes after the start of the test, which should excludes the enqueued tasks @@ -4305,7 +4310,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both enqueued and processing tasks in the first tick, but limited to those with a started_at // that comes before the start of the test, which should excludes all of them @@ -4318,7 +4323,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both enqueued and processing tasks in the first tick, but limited to those with a started_at // that comes after the start of the test and before one minute after the start of the test, @@ -4333,8 +4338,10 @@ mod tests { Start, BatchCreated, ]); + snapshot!(snapshot_index_scheduler(&index_scheduler), name: "after-advancing-a-bit"); let rtxn = index_scheduler.env.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let second_start_time = OffsetDateTime::now_utc(); @@ -4345,7 +4352,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both succeeded and processing tasks in the first tick, but limited to those with a started_at // that comes after the start of the test and before one minute after the start of the test, @@ -4358,7 +4365,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both succeeded and processing tasks in the first tick, but limited to those with a started_at // that comes before the start of the test, which should exclude all tasks @@ -4371,7 +4378,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // both succeeded and processing tasks in the first tick, but limited to those with a started_at // that comes after the start of the second part of the test and before one minute after the @@ -4389,9 +4396,10 @@ mod tests { ]); let rtxn = index_scheduler.env.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // we run the same query to verify that, and indeed find that the last task is matched snapshot!(snapshot_bitmap(&batches), @"[2,]"); @@ -4403,7 +4411,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // enqueued, succeeded, or processing tasks started after the second part of the test, should // again only return the last task @@ -4411,11 +4419,12 @@ mod tests { handle.advance_till([ProcessBatchFailed, AfterProcessing]); let rtxn = index_scheduler.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); // now the last task should have failed snapshot!(snapshot_index_scheduler(&index_scheduler), name: "end"); let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // so running the last query should return nothing snapshot!(snapshot_bitmap(&batches), @"[]"); @@ -4427,7 +4436,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // but the same query on failed tasks should return the last task snapshot!(snapshot_bitmap(&batches), @"[2,]"); @@ -4439,7 +4448,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // but the same query on failed tasks should return the last task snapshot!(snapshot_bitmap(&batches), @"[2,]"); @@ -4452,7 +4461,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // same query but with an invalid uid snapshot!(snapshot_bitmap(&batches), @"[]"); @@ -4465,7 +4474,7 @@ mod tests { ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // same query but with a valid uid snapshot!(snapshot_bitmap(&batches), @"[2,]"); @@ -4494,10 +4503,11 @@ mod tests { handle.advance_till([Start, BatchCreated]); let rtxn = index_scheduler.env.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let query = Query { index_uids: Some(vec!["catto".to_owned()]), ..Default::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // only the first task associated with catto is returned, the indexSwap tasks are excluded! snapshot!(snapshot_bitmap(&batches), @"[0,]"); @@ -4506,6 +4516,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes( &rtxn, + &proc, &query, &AuthFilter::with_allowed_indexes( vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), @@ -4533,6 +4544,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes( &rtxn, + &proc, &query, &AuthFilter::with_allowed_indexes( vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), @@ -4547,6 +4559,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes( &rtxn, + &proc, &query, &AuthFilter::with_allowed_indexes( vec![ @@ -4564,7 +4577,7 @@ mod tests { let query = Query::default(); let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // we asked for all the tasks with all index authorized -> all tasks returned snapshot!(snapshot_bitmap(&batches), @"[0,1,2,3,]"); @@ -4595,9 +4608,10 @@ mod tests { snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); let rtxn = index_scheduler.read_txn().unwrap(); + let proc = index_scheduler.processing_tasks.read().unwrap().clone(); let query = Query { canceled_by: Some(vec![task_cancelation.uid]), ..Query::default() }; let (batches, _) = index_scheduler - .get_batch_ids_from_authorized_indexes(&rtxn, &query, &AuthFilter::default()) + .get_batch_ids_from_authorized_indexes(&rtxn, &proc, &query, &AuthFilter::default()) .unwrap(); // The batch zero was the index creation task, the 1 is the task cancellation snapshot!(snapshot_bitmap(&batches), @"[1,]"); @@ -4606,6 +4620,7 @@ mod tests { let (batches, _) = index_scheduler .get_batch_ids_from_authorized_indexes( &rtxn, + &proc, &query, &AuthFilter::with_allowed_indexes( vec![IndexUidPattern::new_unchecked("doggo")].into_iter().collect(), diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap index 1bf5ce7ba..ee42e932a 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_failing_the_deletion.snap @@ -38,7 +38,7 @@ doggos [0,1,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"providedIds":2,"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap index 27b10199d..0e9e47574 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/document_deletion_and_document_addition/after_last_successful_addition.snap @@ -42,7 +42,7 @@ doggos: { number_of_documents: 3, field_distribution: {"catto": 1, "doggo": 2, " [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"providedIds":2,"deletedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentDeletion":1},"indexUids":{"doggos":1}}, } 1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap index f73c480bc..875ae06c6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_addition/document_addition_failed.snap @@ -35,7 +35,7 @@ doggos [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap index ca5470c5e..114df2852 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_document_deletion/after_removing_the_documents.snap @@ -55,7 +55,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ### All Batches: 0 {uid: 0, details: {"filterableAttributes":["catto"]}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"settingsUpdate":1},"indexUids":{"doggos":1}}, } 1 {uid: 1, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {"providedIds":1,"deletedDocuments":2,"originalFilter":"\"catto EXISTS\""}, stats: {"totalNbTasks":4,"status":{"succeeded":2,"failed":2},"types":{"documentDeletion":4},"indexUids":{"doggos":4}}, } +2 {uid: 2, details: {"providedIds":1,"deletedDocuments":2,"originalFilter":"true&\"id = 2\"&\"catto EXISTS\""}, stats: {"totalNbTasks":4,"status":{"succeeded":2,"failed":2},"types":{"documentDeletion":4},"indexUids":{"doggos":4}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap index 4cc7ad154..b24d0be1e 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/fail_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap index 7d1875617..c776baab7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/panic_in_process_batch_for_index_creation/index_creation_failed.snap @@ -35,7 +35,7 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap index b99e7740b..cbb780494 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/end.snap @@ -50,7 +50,7 @@ doggo: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } 1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } +2 {uid: 2, details: {"primaryKey":"fish"}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap index 982db13a0..31a08e88b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_special_rules/after-processing-everything.snap @@ -55,8 +55,8 @@ doggo: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } 1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } -3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } +2 {uid: 2, details: {"swaps":[{"indexes":["catto","doggo"]}]}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } +3 {uid: 3, details: {"swaps":[{"indexes":["catto","whalo"]}]}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap index b99e7740b..cbb780494 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_simple/end.snap @@ -50,7 +50,7 @@ doggo: { number_of_documents: 0, field_distribution: {} } ### All Batches: 0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } 1 {uid: 1, details: {"primaryKey":"sheep"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"doggo":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } +2 {uid: 2, details: {"primaryKey":"fish"}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexCreation":1},"indexUids":{"whalo":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap index 4d2f86df2..e8e74d0e3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/swap_indexes_errors/first_swap_failed.snap @@ -66,7 +66,7 @@ d: { number_of_documents: 0, field_distribution: {} } 1 {uid: 1, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"b":1}}, } 2 {uid: 2, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"c":1}}, } 3 {uid: 3, details: {"primaryKey":"id"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"d":1}}, } -4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } +4 {uid: 4, details: {"swaps":[{"indexes":["a","b"]},{"indexes":["c","e"]},{"indexes":["d","f"]}]}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"indexSwap":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap index 6e1f526c0..aa27500a7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index/after_processing_the_10_tasks.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":10,"status":{"failed":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } +0 {uid: 0, details: {"receivedDocuments":10,"indexedDocuments":0}, stats: {"totalNbTasks":10,"status":{"failed":10},"types":{"documentAdditionOrUpdate":10},"indexUids":{"doggos":10}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,2,3,4,5,6,7,8,9,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap index 95d454011..e342fb2f3 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/all_tasks_processed.snap @@ -71,16 +71,16 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -5 {uid: 5, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -6 {uid: 6, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -7 {uid: 7, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -8 {uid: 8, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -9 {uid: 9, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +5 {uid: 5, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +6 {uid: 6, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +7 {uid: 7, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +8 {uid: 8, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +9 {uid: 9, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap index 7dbd40e0d..9531dd0bf 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_cant_create_index_without_index_without_autobatching/five_tasks_processed.snap @@ -61,11 +61,11 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -3 {uid: 3, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -4 {uid: 4, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +4 {uid: 4, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap index 2c7faa488..a3609fb1b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/all_tasks_processed.snap @@ -57,7 +57,7 @@ doggos: { number_of_documents: 9, field_distribution: {"doggo": 9, "id": 9} } [timestamp] [1,2,3,4,5,6,7,8,9,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 1 {uid: 1, details: {"receivedDocuments":9,"indexedDocuments":9}, stats: {"totalNbTasks":9,"status":{"succeeded":9},"types":{"documentAdditionOrUpdate":9},"indexUids":{"doggos":9}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap index 18a971baa..d73d749f6 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_mixed_right_without_index_starts_with_cant_create/only_first_task_failed.snap @@ -53,7 +53,7 @@ doggos [0,1,2,3,4,5,6,7,8,9,] [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap index 477520a14..1713c0ac2 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fifth_task_succeeds.snap @@ -51,9 +51,9 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "id": 2} } [timestamp] [4,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +0 {uid: 0, details: {"receivedDocuments":2,"indexedDocuments":0}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } 1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 3 {uid: 3, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap index 1d3281384..96e83ac9b 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/first_and_second_task_fails.snap @@ -44,7 +44,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +0 {uid: 0, details: {"receivedDocuments":2,"indexedDocuments":0}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap index 5cf144edd..f54713081 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/fourth_task_fails.snap @@ -49,9 +49,9 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [3,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +0 {uid: 0, details: {"receivedDocuments":2,"indexedDocuments":0}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } 1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap index 7adc83fd3..0f24a6715 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_bad_primary_key/third_task_succeeds.snap @@ -47,7 +47,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } +0 {uid: 0, details: {"receivedDocuments":2,"indexedDocuments":0}, stats: {"totalNbTasks":2,"status":{"failed":2},"types":{"documentAdditionOrUpdate":2},"indexUids":{"doggos":2}}, } 1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap index b7098b60a..b49d3ea64 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/second_task_fails.snap @@ -44,7 +44,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap index 63c1b5f89..35783d84f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key/third_task_fails.snap @@ -46,8 +46,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -2 {uid: 2, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap index 52391905d..2c6d29a18 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_multiple_primary_key_batch_wrong_key/second_and_third_tasks_fails.snap @@ -44,7 +44,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "id": 1} } ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap index 526407329..6d3fabe77 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/all_other_tasks_succeeds.snap @@ -53,8 +53,8 @@ doggos: { number_of_documents: 4, field_distribution: {"doggo": 4, "paw": 4} } [timestamp] [3,4,5,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":3,"status":{"succeeded":3},"types":{"documentAdditionOrUpdate":3},"indexUids":{"doggos":3}}, } ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap index 41517d90b..5b304aa24 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/first_task_fails.snap @@ -46,7 +46,7 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [0,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap index a46f9078d..b5e113599 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/second_task_fails.snap @@ -48,8 +48,8 @@ doggos: { number_of_documents: 0, field_distribution: {} } [timestamp] [1,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap index 0f6c32310..0f3730932 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key/third_task_succeeds.snap @@ -51,8 +51,8 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "paw": 1} } [timestamp] [2,] ---------------------------------------------------------------------- ### All Batches: -0 {uid: 0, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap index 0b294a0d1..46408e0a7 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/all_other_tasks_succeeds.snap @@ -54,7 +54,7 @@ doggos: { number_of_documents: 5, field_distribution: {"doggo": 5, "doggoid": 5} ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 3 {uid: 3, details: {"receivedDocuments":3,"indexedDocuments":3}, stats: {"totalNbTasks":3,"status":{"succeeded":3},"types":{"documentAdditionOrUpdate":3},"indexUids":{"doggos":3}}, } ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap index 5c78a6550..828c28298 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/second_task_fails.snap @@ -50,7 +50,7 @@ doggos: { number_of_documents: 1, field_distribution: {"doggo": 1, "doggoid": 1} ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap index 6baa913fe..7e9a02288 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/test_document_addition_with_set_and_null_primary_key_inference_works/third_task_succeeds.snap @@ -52,7 +52,7 @@ doggos: { number_of_documents: 2, field_distribution: {"doggo": 2, "doggoid": 2} ---------------------------------------------------------------------- ### All Batches: 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } -1 {uid: 1, details: {}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } +1 {uid: 1, details: {"receivedDocuments":1,"indexedDocuments":0}, stats: {"totalNbTasks":1,"status":{"failed":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } 2 {uid: 2, details: {"receivedDocuments":1,"indexedDocuments":1}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"documentAdditionOrUpdate":1},"indexUids":{"doggos":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 6311359b3..3362d802f 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -12,7 +12,7 @@ use meilisearch_types::tasks::{Details, IndexSwap, Kind, KindWithContent, Status use roaring::{MultiOps, RoaringBitmap}; use time::OffsetDateTime; -use crate::{Error, IndexScheduler, Result, Task, TaskId, BEI128}; +use crate::{Error, IndexScheduler, ProcessingTasks, Result, Task, TaskId, BEI128}; /// This structure contains all the information required to write a batch in the database without reading the tasks. /// It'll stay in RAM so it must be small. @@ -106,10 +106,8 @@ impl ProcessingBatch { self.statuses.insert(task.status); // Craft an aggregation of the details of all the tasks encountered in this batch. - if task.status != Status::Failed { - if let Some(ref details) = task.details { - self.details.accumulate(&DetailsView::from(details.clone())); - } + if let Some(ref details) = task.details { + self.details.accumulate(&DetailsView::from(details.clone())); } self.stats.total_nb_tasks += 1; *self.stats.status.entry(task.status).or_default() += 1; @@ -118,6 +116,16 @@ impl ProcessingBatch { *self.stats.index_uids.entry(index_uid.to_string()).or_default() += 1; } } + + pub fn to_batch(&self) -> Batch { + Batch { + uid: self.uid, + details: self.details.clone(), + stats: self.stats.clone(), + started_at: self.started_at, + finished_at: self.finished_at, + } + } } impl IndexScheduler { @@ -243,13 +251,18 @@ impl IndexScheduler { pub(crate) fn get_existing_batches( &self, rtxn: &RoTxn, + processing: &ProcessingTasks, tasks: impl IntoIterator, ) -> Result> { tasks .into_iter() .map(|batch_id| { - self.get_batch(rtxn, batch_id) - .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)) + if Some(batch_id) == processing.batch.as_ref().map(|batch| batch.uid) { + Ok(processing.batch.as_ref().unwrap().to_batch()) + } else { + self.get_batch(rtxn, batch_id) + .and_then(|task| task.ok_or(Error::CorruptedTaskQueue)) + } }) .collect::>() } diff --git a/crates/meilisearch/src/routes/batches.rs b/crates/meilisearch/src/routes/batches.rs index 9e432bcc1..d01bd5965 100644 --- a/crates/meilisearch/src/routes/batches.rs +++ b/crates/meilisearch/src/routes/batches.rs @@ -42,7 +42,7 @@ async fn get_batch( let task_view = BatchView::from_batch(batch); Ok(HttpResponse::Ok().json(task_view)) } else { - Err(index_scheduler::Error::TaskNotFound(batch_uid).into()) + Err(index_scheduler::Error::BatchNotFound(batch_uid).into()) } } diff --git a/crates/meilisearch/tests/batches/mod.rs b/crates/meilisearch/tests/batches/mod.rs index f04c7042e..ba9b8ea3a 100644 --- a/crates/meilisearch/tests/batches/mod.rs +++ b/crates/meilisearch/tests/batches/mod.rs @@ -2,8 +2,6 @@ mod errors; use meili_snap::insta::assert_json_snapshot; use meili_snap::snapshot; -use time::format_description::well_known::Rfc3339; -use time::OffsetDateTime; use crate::common::Server; use crate::json; @@ -17,7 +15,7 @@ async fn error_get_unexisting_batch_status() { let (response, code) = index.get_batch(1).await; let expected_response = json!({ - "message": "batch `1` not found.", + "message": "Batch `1` not found.", "code": "batch_not_found", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#batch_not_found" @@ -32,19 +30,9 @@ async fn get_batch_status() { let server = Server::new().await; let index = server.index("test"); index.create(None).await; - index - .add_documents( - json!([{ - "id": 1, - "content": "foobar", - }]), - None, - ) - .await; index.wait_task(0).await; - let (_response, code) = index.get_batch(1).await; + let (_response, code) = index.get_batch(0).await; assert_eq!(code, 200); - // TODO check response format, as per #48 } #[actix_rt::test] @@ -241,49 +229,6 @@ async fn get_batch_filter_error() { "#); } -macro_rules! assert_valid_summarized_batch { - ($response:expr, $batch_type:literal, $index:literal) => {{ - assert_eq!($response.as_object().unwrap().len(), 5); - assert!($response["batchUid"].as_u64().is_some()); - assert_eq!($response["indexUid"], $index); - assert_eq!($response["status"], "enqueued"); - assert_eq!($response["type"], $batch_type); - let date = $response["enqueuedAt"].as_str().expect("missing date"); - - OffsetDateTime::parse(date, &Rfc3339).unwrap(); - }}; -} - -#[actix_web::test] -async fn test_summarized_batch_view() { - let server = Server::new().await; - let index = server.index("test"); - - let (response, _) = index.create(None).await; - assert_valid_summarized_batch!(response, "indexCreation", "test"); - - let (response, _) = index.update(None).await; - assert_valid_summarized_batch!(response, "indexUpdate", "test"); - - let (response, _) = index.update_settings(json!({})).await; - assert_valid_summarized_batch!(response, "settingsUpdate", "test"); - - let (response, _) = index.update_documents(json!([{"id": 1}]), None).await; - assert_valid_summarized_batch!(response, "documentAdditionOrUpdate", "test"); - - let (response, _) = index.add_documents(json!([{"id": 1}]), None).await; - assert_valid_summarized_batch!(response, "documentAdditionOrUpdate", "test"); - - let (response, _) = index.delete_document(1).await; - assert_valid_summarized_batch!(response, "documentDeletion", "test"); - - let (response, _) = index.clear_all_documents().await; - assert_valid_summarized_batch!(response, "documentDeletion", "test"); - - let (response, _) = index.delete().await; - assert_valid_summarized_batch!(response, "indexDeletion", "test"); -} - #[actix_web::test] async fn test_summarized_document_addition_or_update() { let server = Server::new().await; @@ -361,7 +306,10 @@ async fn test_summarized_delete_documents_by_batch() { @r#" { "uid": 0, - "details": {}, + "details": { + "providedIds": 3, + "deletedDocuments": 0 + }, "stats": { "totalNbTasks": 1, "status": { @@ -425,7 +373,11 @@ async fn test_summarized_delete_documents_by_filter() { @r#" { "uid": 0, - "details": {}, + "details": { + "providedIds": 0, + "deletedDocuments": 0, + "originalFilter": "\"doggo = bernese\"" + }, "stats": { "totalNbTasks": 1, "status": { @@ -453,7 +405,11 @@ async fn test_summarized_delete_documents_by_filter() { @r#" { "uid": 2, - "details": {}, + "details": { + "providedIds": 0, + "deletedDocuments": 0, + "originalFilter": "\"doggo = bernese\"" + }, "stats": { "totalNbTasks": 1, "status": { @@ -517,7 +473,10 @@ async fn test_summarized_delete_document_by_id() { @r#" { "uid": 0, - "details": {}, + "details": { + "providedIds": 1, + "deletedDocuments": 0 + }, "stats": { "totalNbTasks": 1, "status": { @@ -663,7 +622,9 @@ async fn test_summarized_index_creation() { @r#" { "uid": 1, - "details": {}, + "details": { + "primaryKey": "doggos" + }, "stats": { "totalNbTasks": 1, "status": { @@ -832,7 +793,9 @@ async fn test_summarized_index_update() { @r#" { "uid": 1, - "details": {}, + "details": { + "primaryKey": "bones" + }, "stats": { "totalNbTasks": 1, "status": { @@ -926,7 +889,16 @@ async fn test_summarized_index_swap() { @r#" { "uid": 0, - "details": {}, + "details": { + "swaps": [ + { + "indexes": [ + "doggos", + "cattos" + ] + } + ] + }, "stats": { "totalNbTasks": 1, "status": { From d9a4e69990312c94cf92e7de8c80a3cc26605772 Mon Sep 17 00:00:00 2001 From: Tamo Date: Tue, 19 Nov 2024 19:42:36 +0100 Subject: [PATCH 13/22] push a missing snapshot --- .../after-advancing-a-bit.snap | 70 +++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100644 crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/after-advancing-a-bit.snap diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/after-advancing-a-bit.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/after-advancing-a-bit.snap new file mode 100644 index 000000000..bbe6f7d61 --- /dev/null +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_simple/after-advancing-a-bit.snap @@ -0,0 +1,70 @@ +--- +source: crates/index-scheduler/src/lib.rs +snapshot_kind: text +--- +### Autobatching Enabled = true +### Processing batch Some(1): +[1,] +---------------------------------------------------------------------- +### All Tasks: +0 {uid: 0, batch_uid: 0, status: succeeded, details: { primary_key: Some("mouse") }, kind: IndexCreation { index_uid: "catto", primary_key: Some("mouse") }} +1 {uid: 1, status: enqueued, details: { primary_key: Some("sheep") }, kind: IndexCreation { index_uid: "doggo", primary_key: Some("sheep") }} +2 {uid: 2, status: enqueued, details: { primary_key: Some("fish") }, kind: IndexCreation { index_uid: "whalo", primary_key: Some("fish") }} +---------------------------------------------------------------------- +### Status: +enqueued [1,2,] +succeeded [0,] +---------------------------------------------------------------------- +### Kind: +"indexCreation" [0,1,2,] +---------------------------------------------------------------------- +### Index Tasks: +catto [0,] +doggo [1,] +whalo [2,] +---------------------------------------------------------------------- +### Index Mapper: +catto: { number_of_documents: 0, field_distribution: {} } + +---------------------------------------------------------------------- +### Canceled By: + +---------------------------------------------------------------------- +### Enqueued At: +[timestamp] [0,] +[timestamp] [1,] +[timestamp] [2,] +---------------------------------------------------------------------- +### Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- +### All Batches: +0 {uid: 0, details: {"primaryKey":"mouse"}, stats: {"totalNbTasks":1,"status":{"succeeded":1},"types":{"indexCreation":1},"indexUids":{"catto":1}}, } +---------------------------------------------------------------------- +### Batch to tasks mapping: +0 [0,] +---------------------------------------------------------------------- +### Batches Status: +succeeded [0,] +---------------------------------------------------------------------- +### Batches Kind: +"indexCreation" [0,] +---------------------------------------------------------------------- +### Batches Index Tasks: +catto [0,] +---------------------------------------------------------------------- +### Batches Enqueued At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Started At: +[timestamp] [0,] +---------------------------------------------------------------------- +### Batches Finished At: +[timestamp] [0,] +---------------------------------------------------------------------- +### File Store: + +---------------------------------------------------------------------- From e145d71a6221b074d86b1db86350dbea2cb4febd Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 10:23:45 +0100 Subject: [PATCH 14/22] implements the two last TODOs --- crates/index-scheduler/src/lib.rs | 14 +++++++------- crates/index-scheduler/src/utils.rs | 21 +++++++-------------- 2 files changed, 14 insertions(+), 21 deletions(-) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 9541e9736..4c7d9e363 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -67,7 +67,7 @@ use roaring::RoaringBitmap; use synchronoise::SignalEvent; use time::format_description::well_known::Rfc3339; use time::OffsetDateTime; -use utils::{filter_out_references_to_newer_tasks, keep_tasks_within_datetimes, map_bound}; +use utils::{filter_out_references_to_newer_tasks, keep_ids_within_datetimes, map_bound}; use uuid::Uuid; use crate::index_mapper::IndexMapper; @@ -904,7 +904,7 @@ impl IndexScheduler { ), }; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut filtered_non_processing_tasks, self.started_at, @@ -914,7 +914,7 @@ impl IndexScheduler { filtered_non_processing_tasks | filtered_processing_tasks }; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut tasks, self.enqueued_at, @@ -922,7 +922,7 @@ impl IndexScheduler { *before_enqueued_at, )?; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut tasks, self.finished_at, @@ -1092,7 +1092,7 @@ impl IndexScheduler { ), }; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut filtered_non_processing_batches, self.batch_started_at, @@ -1102,7 +1102,7 @@ impl IndexScheduler { filtered_non_processing_batches | filtered_processing_batches }; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut batches, self.batch_enqueued_at, @@ -1110,7 +1110,7 @@ impl IndexScheduler { query.before_enqueued_at, )?; - keep_tasks_within_datetimes( + keep_ids_within_datetimes( rtxn, &mut batches, self.batch_finished_at, diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 3362d802f..827cdf95e 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -270,16 +270,10 @@ impl IndexScheduler { pub(crate) fn update_task(&self, wtxn: &mut RwTxn, task: &Task) -> Result<()> { let old_task = self.get_task(wtxn, task.uid)?.ok_or(Error::CorruptedTaskQueue)?; - dbg!(&task); - + debug_assert!(old_task != *task); debug_assert_eq!(old_task.uid, task.uid); debug_assert!(old_task.batch_uid.is_none() && task.batch_uid.is_some()); - // TODO: This shouldn't ever happen, we should assert it - if old_task == *task { - return Ok(()); - } - if old_task.status != task.status { self.update_status(wtxn, old_task.status, |bitmap| { bitmap.remove(task.uid); @@ -505,10 +499,9 @@ pub(crate) fn remove_task_datetime( Ok(()) } -// TODO: Rename the function since it also applies to batches -pub(crate) fn keep_tasks_within_datetimes( +pub(crate) fn keep_ids_within_datetimes( rtxn: &RoTxn, - tasks: &mut RoaringBitmap, + ids: &mut RoaringBitmap, database: Database, after: Option, before: Option, @@ -519,15 +512,15 @@ pub(crate) fn keep_tasks_within_datetimes( (Some(after), None) => (Bound::Excluded(*after), Bound::Unbounded), (Some(after), Some(before)) => (Bound::Excluded(*after), Bound::Excluded(*before)), }; - let mut collected_task_ids = RoaringBitmap::new(); + let mut collected_ids = RoaringBitmap::new(); let start = map_bound(start, |b| b.unix_timestamp_nanos()); let end = map_bound(end, |b| b.unix_timestamp_nanos()); let iter = database.range(rtxn, &(start, end))?; for r in iter { - let (_timestamp, task_ids) = r?; - collected_task_ids |= task_ids; + let (_timestamp, ids) = r?; + collected_ids |= ids; } - *tasks &= collected_task_ids; + *ids &= collected_ids; Ok(()) } From b24a34830da5333a1e44516e7940332c84f8969e Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 10:31:10 +0100 Subject: [PATCH 15/22] fix the dump test -> the only change is that we now have a null batch_uid in all the tasks --- crates/dump/src/reader/compat/v5_to_v6.rs | 2 +- crates/dump/src/reader/mod.rs | 16 ++++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/crates/dump/src/reader/compat/v5_to_v6.rs b/crates/dump/src/reader/compat/v5_to_v6.rs index 9887c55ba..785542cce 100644 --- a/crates/dump/src/reader/compat/v5_to_v6.rs +++ b/crates/dump/src/reader/compat/v5_to_v6.rs @@ -450,7 +450,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"41f91d3a94911b2735ec41b07540df5c"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"4b03e23e740b27bfb9d2a1faffe512e2"); assert_eq!(update_files.len(), 22); assert!(update_files[0].is_none()); // the dump creation assert!(update_files[1].is_some()); // the enqueued document addition diff --git a/crates/dump/src/reader/mod.rs b/crates/dump/src/reader/mod.rs index 4f66ed8b3..f9660972a 100644 --- a/crates/dump/src/reader/mod.rs +++ b/crates/dump/src/reader/mod.rs @@ -222,7 +222,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"278f63325ef06ca04d01df98d8207b94"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"2b8a72d6bc6ba79980491966437daaf9"); assert_eq!(update_files.len(), 10); assert!(update_files[0].is_none()); // the dump creation assert!(update_files[1].is_none()); @@ -345,7 +345,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"d45cd8571703e58ae53c7bd7ce3f5c22"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"3ddf6169b0a3703c5d770971f036fc5d"); assert_eq!(update_files.len(), 2); assert!(update_files[0].is_none()); // the dump creation assert!(update_files[1].is_none()); // the processed document addition @@ -391,7 +391,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"41f91d3a94911b2735ec41b07540df5c"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"4b03e23e740b27bfb9d2a1faffe512e2"); assert_eq!(update_files.len(), 22); assert!(update_files[0].is_none()); // the dump creation assert!(update_files[1].is_some()); // the enqueued document addition @@ -471,7 +471,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"c2445ddd1785528b80f2ba534d3bd00c"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"c1b06a5ca60d5805483c16c5b3ff61ef"); assert_eq!(update_files.len(), 10); assert!(update_files[0].is_some()); // the enqueued document addition assert!(update_files[1..].iter().all(|u| u.is_none())); // everything already processed @@ -548,7 +548,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"cd12efd308fe3ed226356a727ab42ed3"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"0e203b6095f7c68dbdf788321dcc8215"); assert_eq!(update_files.len(), 10); assert!(update_files[0].is_some()); // the enqueued document addition assert!(update_files[1..].iter().all(|u| u.is_none())); // everything already processed @@ -641,7 +641,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"bc616290adfe7d09a624cf6065ca9069"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"d216c7f90f538ffbb2a059531d7ac89a"); assert_eq!(update_files.len(), 9); assert!(update_files[0].is_some()); // the enqueued document addition assert!(update_files[1..].iter().all(|u| u.is_none())); // everything already processed @@ -734,7 +734,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"2db37756d8af1fb7623436b76e8956a6"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"e27999f1112632222cb84f6cffff7c5f"); assert_eq!(update_files.len(), 8); assert!(update_files[0..].iter().all(|u| u.is_none())); // everything already processed @@ -810,7 +810,7 @@ pub(crate) mod test { // tasks let tasks = dump.tasks().unwrap().collect::>>().unwrap(); let (tasks, update_files): (Vec<_>, Vec<_>) = tasks.into_iter().unzip(); - meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"8df6eab075a44b3c1af6b726f9fd9a43"); + meili_snap::snapshot_hash!(meili_snap::json_string!(tasks), @"0155a664b0cf62aae23db5138b6b03d7"); assert_eq!(update_files.len(), 9); assert!(update_files[..].iter().all(|u| u.is_none())); // no update file in dump v1 From bdb51a85fefb7e17abfe010d43d8449ad105a0d6 Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 10:42:29 +0100 Subject: [PATCH 16/22] now that the task cancelation shares their started at with all the tasks of their batch we don't need the trick of retrieving the previous batch anymore --- crates/index-scheduler/src/batch.rs | 26 +++----------------------- 1 file changed, 3 insertions(+), 23 deletions(-) diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index b43efd899..8d6d3e49b 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -46,7 +46,7 @@ use uuid::Uuid; use crate::autobatcher::{self, BatchKind}; use crate::utils::{self, swap_index_uid_in_task, ProcessingBatch}; -use crate::{Error, IndexScheduler, MustStopProcessing, ProcessingTasks, Result, TaskId}; +use crate::{Error, IndexScheduler, MustStopProcessing, Result, TaskId}; /// Represents a combination of tasks that can all be processed at the same time. /// @@ -58,10 +58,6 @@ pub(crate) enum Batch { TaskCancelation { /// The task cancelation itself. task: Task, - /// The date and time at which the previously processing tasks started. - previous_started_at: OffsetDateTime, - /// The list of tasks that were processing when this task cancelation appeared. - previous_processing_tasks: RoaringBitmap, }, TaskDeletions(Vec), SnapshotCreation(Vec), @@ -556,25 +552,9 @@ impl IndexScheduler { // 1. we get the last task to cancel. if let Some(task_id) = to_cancel.max() { - // We retrieve the tasks that were processing before this tasks cancelation started. - // We must *not* reset the processing tasks before calling this method. - // Displaying the `batch_id` would make a strange error message since this task cancelation is going to - // replace the canceled batch. It's better to avoid mentioning it in the error message. - let ProcessingTasks { batch: previous_batch, processing } = - &*self.processing_tasks.read().unwrap(); let mut task = self.get_task(rtxn, task_id)?.ok_or(Error::CorruptedTaskQueue)?; current_batch.processing(Some(&mut task)); - return Ok(Some(( - Batch::TaskCancelation { - task, - // We should never be in a case where we don't have a previous_batch, but let's not crash if it happens - previous_started_at: previous_batch - .as_ref() - .map_or_else(OffsetDateTime::now_utc, |batch| batch.started_at), - previous_processing_tasks: processing.clone(), - }, - current_batch, - ))); + return Ok(Some((Batch::TaskCancelation { task }, current_batch))); } // 2. we get the next task to delete @@ -681,7 +661,7 @@ impl IndexScheduler { } match batch { - Batch::TaskCancelation { mut task, previous_started_at, previous_processing_tasks } => { + Batch::TaskCancelation { mut task } => { // 1. Retrieve the tasks that matched the query at enqueue-time. let matched_tasks = if let KindWithContent::TaskCancelation { tasks, query: _ } = &task.kind { From 56eacd221f9069dc2565cd8bfdc6c0ee9185b3b4 Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 10:54:38 +0100 Subject: [PATCH 17/22] update the tests after the rebase --- crates/meilisearch/tests/batches/mod.rs | 6 +++--- crates/meilisearch/tests/tasks/errors.rs | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/crates/meilisearch/tests/batches/mod.rs b/crates/meilisearch/tests/batches/mod.rs index ba9b8ea3a..d715c29af 100644 --- a/crates/meilisearch/tests/batches/mod.rs +++ b/crates/meilisearch/tests/batches/mod.rs @@ -186,14 +186,14 @@ async fn get_batch_filter_error() { let (response, code) = server.batches_filter("lol=pied").await; assert_eq!(code, 400, "{}", response); - meili_snap::snapshot!(meili_snap::json_string!(response), @r###" + meili_snap::snapshot!(meili_snap::json_string!(response), @r#" { - "message": "Unknown parameter `lol`: expected one of `limit`, `from`, `batchUids`, `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `lol`: expected one of `limit`, `from`, `reverse`, `batchUids`, `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" } - "###); + "#); let (response, code) = server.batches_filter("uids=pied").await; assert_eq!(code, 400, "{}", response); diff --git a/crates/meilisearch/tests/tasks/errors.rs b/crates/meilisearch/tests/tasks/errors.rs index 2ff497db9..932dd19d4 100644 --- a/crates/meilisearch/tests/tasks/errors.rs +++ b/crates/meilisearch/tests/tasks/errors.rs @@ -307,25 +307,25 @@ async fn task_bad_reverse() { let (response, code) = server.cancel_tasks("reverse=doggo").await; snapshot!(code, @"400 Bad Request"); - snapshot!(response, @r###" + snapshot!(response, @r#" { - "message": "Unknown parameter `reverse`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `reverse`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" } - "###); + "#); let (response, code) = server.delete_tasks("reverse=doggo").await; snapshot!(code, @"400 Bad Request"); - snapshot!(response, @r###" + snapshot!(response, @r#" { - "message": "Unknown parameter `reverse`: expected one of `uids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", + "message": "Unknown parameter `reverse`: expected one of `uids`, `batchUids`, `canceledBy`, `types`, `statuses`, `indexUids`, `afterEnqueuedAt`, `beforeEnqueuedAt`, `afterStartedAt`, `beforeStartedAt`, `afterFinishedAt`, `beforeFinishedAt`", "code": "bad_request", "type": "invalid_request", "link": "https://docs.meilisearch.com/errors#bad_request" } - "###); + "#); } #[actix_rt::test] From 7e379b3d14fc19a5302fe6b8bee7594f90728919 Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 12:27:12 +0100 Subject: [PATCH 18/22] remove useless prints --- crates/index-scheduler/src/lib.rs | 2 -- crates/meilisearch/tests/snapshot/mod.rs | 1 - crates/meilitool/src/upgrade/v1_10.rs | 7 ------- 3 files changed, 10 deletions(-) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 4c7d9e363..36ab93eb0 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -948,7 +948,6 @@ impl IndexScheduler { processing: &ProcessingTasks, query: &Query, ) -> Result { - dbg!(); let mut batches = self.all_batch_ids(rtxn)?; if let Some(batch_id) = processing.batch.as_ref().map(|batch| batch.uid) { batches.insert(batch_id); @@ -4160,7 +4159,6 @@ mod tests { tasks: [0, 1, 2, 3].into_iter().collect(), }; let task_cancelation = index_scheduler.register(kind, None, false).unwrap(); - println!("HEEERE"); handle.advance_n_successful_batches(1); snapshot!(snapshot_index_scheduler(&index_scheduler), name: "start"); diff --git a/crates/meilisearch/tests/snapshot/mod.rs b/crates/meilisearch/tests/snapshot/mod.rs index b4454a7f2..976551190 100644 --- a/crates/meilisearch/tests/snapshot/mod.rs +++ b/crates/meilisearch/tests/snapshot/mod.rs @@ -65,7 +65,6 @@ async fn perform_snapshot() { let next_task = task.uid() + 1; loop { let (value, code) = index.get_task(next_task).await; - dbg!(&value); if code != 404 && value["status"].as_str() == Some("succeeded") { break; } diff --git a/crates/meilitool/src/upgrade/v1_10.rs b/crates/meilitool/src/upgrade/v1_10.rs index 3dd7c72a2..2efc1773c 100644 --- a/crates/meilitool/src/upgrade/v1_10.rs +++ b/crates/meilitool/src/upgrade/v1_10.rs @@ -76,13 +76,6 @@ fn update_index_stats( ) -> anyhow::Result<()> { let ctx = || format!("while updating index stats for index `{index_uid}`"); - let stats: Option<&str> = index_stats - .remap_data_type::() - .get(sched_wtxn, &index_uuid) - .with_context(ctx) - .with_context(|| "While reading value")?; - dbg!(stats); - let stats: Option = index_stats .remap_data_type::>() .get(sched_wtxn, &index_uuid) From 8ad68dd7088c71df821a63aab998c80992496515 Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 13:17:54 +0100 Subject: [PATCH 19/22] stop leaking the update files of the canceled tasks --- crates/index-scheduler/src/lib.rs | 13 ++++++++----- .../cancel_enqueued_task/cancel_processed.snap | 3 +-- .../cancel_mix_of_tasks/cancel_processed.snap | 4 +--- .../cancel_processing_dump/cancel_processed.snap | 2 +- .../cancel_processing_task/cancel_processed.snap | 3 +-- .../lib.rs/query_batches_canceled_by/start.snap | 2 +- .../lib.rs/query_tasks_canceled_by/start.snap | 2 +- 7 files changed, 14 insertions(+), 15 deletions(-) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 36ab93eb0..b976d7342 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -1556,7 +1556,7 @@ impl IndexScheduler { drop(rtxn); // 1. store the starting date with the bitmap of processing tasks. - let ids = batch.ids(); + let mut ids = batch.ids(); let processed_tasks = ids.len(); // We reset the must_stop flag to be sure that we don't stop processing tasks @@ -1593,6 +1593,7 @@ impl IndexScheduler { processing_batch.finished(); let mut wtxn = self.env.write_txn().map_err(Error::HeedTransaction)?; + let mut canceled = RoaringBitmap::new(); match res { Ok(tasks) => { @@ -1602,7 +1603,6 @@ impl IndexScheduler { let mut success = 0; let mut failure = 0; let mut canceled_by = None; - let mut canceled = RoaringBitmap::new(); #[allow(unused_variables)] for (i, mut task) in tasks.into_iter().enumerate() { @@ -1693,9 +1693,12 @@ impl IndexScheduler { } } - let processed = self.processing_tasks.write().unwrap().stop_processing(); + self.processing_tasks.write().unwrap().stop_processing(); + // We must re-add the canceled task so they're part of the same batch. + // processed.processing |= canceled; + ids |= canceled; - self.write_batch(&mut wtxn, processing_batch, &processed.processing)?; + self.write_batch(&mut wtxn, processing_batch, &ids)?; #[cfg(test)] self.maybe_fail(tests::FailureLocation::CommittingWtxn)?; @@ -1725,7 +1728,7 @@ impl IndexScheduler { })?; // We shouldn't crash the tick function if we can't send data to the webhook. - let _ = self.notify_webhook(&processed.processing); + let _ = self.notify_webhook(&ids); #[cfg(test)] self.breakpoint(Breakpoint::AfterProcessing); diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap index fa67aa779..f0c382d86 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_enqueued_task/cancel_processed.snap @@ -43,7 +43,7 @@ catto [0,] 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"documentAdditionOrUpdate":1,"taskCancelation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: -0 [1,] +0 [0,1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] @@ -67,6 +67,5 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### File Store: -00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap index d94494a26..444b171dd 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_mix_of_tasks/cancel_processed.snap @@ -55,7 +55,7 @@ catto: { number_of_documents: 1, field_distribution: {"id": 1} } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] -1 [3,] +1 [1,2,3,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] @@ -84,7 +84,5 @@ wolfo [1,] [timestamp] [1,] ---------------------------------------------------------------------- ### File Store: -00000000-0000-0000-0000-000000000001 -00000000-0000-0000-0000-000000000002 ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap index 670116fe1..dbae3a082 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_dump/cancel_processed.snap @@ -42,7 +42,7 @@ canceled [0,] 0 {uid: 0, details: {"matchedTasks":1,"canceledTasks":1,"originalFilter":"cancel dump"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"taskCancelation":1,"dumpCreation":1},"indexUids":{}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: -0 [1,] +0 [0,1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap index ece94e06a..ef6845b05 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/cancel_processing_task/cancel_processed.snap @@ -44,7 +44,7 @@ catto: { number_of_documents: 0, field_distribution: {} } 0 {uid: 0, details: {"receivedDocuments":1,"indexedDocuments":0,"matchedTasks":1,"canceledTasks":1,"originalFilter":"test_query"}, stats: {"totalNbTasks":2,"status":{"succeeded":1,"canceled":1},"types":{"documentAdditionOrUpdate":1,"taskCancelation":1},"indexUids":{"catto":1}}, } ---------------------------------------------------------------------- ### Batch to tasks mapping: -0 [1,] +0 [0,1,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,] @@ -68,6 +68,5 @@ catto [0,] [timestamp] [0,] ---------------------------------------------------------------------- ### File Store: -00000000-0000-0000-0000-000000000000 ---------------------------------------------------------------------- diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap index 79c5e6499..ea3a75e8f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_batches_canceled_by/start.snap @@ -54,7 +54,7 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] -1 [3,] +1 [1,2,3,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] diff --git a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap index 79c5e6499..ea3a75e8f 100644 --- a/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap +++ b/crates/index-scheduler/src/snapshots/lib.rs/query_tasks_canceled_by/start.snap @@ -54,7 +54,7 @@ catto: { number_of_documents: 0, field_distribution: {} } ---------------------------------------------------------------------- ### Batch to tasks mapping: 0 [0,] -1 [3,] +1 [1,2,3,] ---------------------------------------------------------------------- ### Batches Status: succeeded [0,1,] From a7ac590e9efdd052997d7df7785a8cfe8d00d7cd Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 13:29:52 +0100 Subject: [PATCH 20/22] implements the reverse query parameter for the batches --- crates/index-scheduler/src/lib.rs | 76 +++++++++++++++------- crates/meilisearch/tests/batches/errors.rs | 27 ++++++++ crates/meilisearch/tests/batches/mod.rs | 38 +++++++++++ 3 files changed, 119 insertions(+), 22 deletions(-) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index b976d7342..083363c95 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -948,21 +948,44 @@ impl IndexScheduler { processing: &ProcessingTasks, query: &Query, ) -> Result { + let Query { + limit, + from, + reverse, + uids, + batch_uids, + statuses, + types, + index_uids, + canceled_by, + before_enqueued_at, + after_enqueued_at, + before_started_at, + after_started_at, + before_finished_at, + after_finished_at, + } = query; + let mut batches = self.all_batch_ids(rtxn)?; if let Some(batch_id) = processing.batch.as_ref().map(|batch| batch.uid) { batches.insert(batch_id); } - if let Some(from) = &query.from { - batches.remove_range(from.saturating_add(1)..); + if let Some(from) = from { + let range = if reverse.unwrap_or_default() { + u32::MIN..*from + } else { + from.saturating_add(1)..u32::MAX + }; + batches.remove_range(range); } - if let Some(batch_uids) = &query.batch_uids { + if let Some(batch_uids) = &batch_uids { let batches_uids = RoaringBitmap::from_iter(batch_uids); batches &= batches_uids; } - if let Some(status) = &query.statuses { + if let Some(status) = &statuses { let mut status_batches = RoaringBitmap::new(); for status in status { match status { @@ -985,7 +1008,7 @@ impl IndexScheduler { batches &= status_batches; } - if let Some(task_uids) = &query.uids { + if let Some(task_uids) = &uids { let mut batches_by_task_uids = RoaringBitmap::new(); for task_uid in task_uids { if let Some(task) = self.get_task(rtxn, *task_uid)? { @@ -998,7 +1021,7 @@ impl IndexScheduler { } // There is no database for this query, we must retrieve the task queried by the client and ensure it's valid - if let Some(canceled_by) = &query.canceled_by { + if let Some(canceled_by) = &canceled_by { let mut all_canceled_batches = RoaringBitmap::new(); for cancel_uid in canceled_by { if let Some(task) = self.get_task(rtxn, *cancel_uid)? { @@ -1021,7 +1044,7 @@ impl IndexScheduler { } } - if let Some(kind) = &query.types { + if let Some(kind) = &types { let mut kind_batches = RoaringBitmap::new(); for kind in kind { kind_batches |= self.get_batch_kind(rtxn, *kind)?; @@ -1036,7 +1059,7 @@ impl IndexScheduler { batches &= &kind_batches; } - if let Some(index) = &query.index_uids { + if let Some(index) = &index_uids { let mut index_batches = RoaringBitmap::new(); for index in index { index_batches |= self.index_batches(rtxn, index)?; @@ -1077,17 +1100,17 @@ impl IndexScheduler { filtered_processing_batches.clear(); } }; - match (query.after_started_at, query.before_started_at) { + match (after_started_at, before_started_at) { (None, None) => (), (None, Some(before)) => { - clear_filtered_processing_batches(Bound::Unbounded, Bound::Excluded(before)) + clear_filtered_processing_batches(Bound::Unbounded, Bound::Excluded(*before)) } (Some(after), None) => { - clear_filtered_processing_batches(Bound::Excluded(after), Bound::Unbounded) + clear_filtered_processing_batches(Bound::Excluded(*after), Bound::Unbounded) } (Some(after), Some(before)) => clear_filtered_processing_batches( - Bound::Excluded(after), - Bound::Excluded(before), + Bound::Excluded(*after), + Bound::Excluded(*before), ), }; @@ -1095,8 +1118,8 @@ impl IndexScheduler { rtxn, &mut filtered_non_processing_batches, self.batch_started_at, - query.after_started_at, - query.before_started_at, + *after_started_at, + *before_started_at, )?; filtered_non_processing_batches | filtered_processing_batches }; @@ -1105,20 +1128,24 @@ impl IndexScheduler { rtxn, &mut batches, self.batch_enqueued_at, - query.after_enqueued_at, - query.before_enqueued_at, + *after_enqueued_at, + *before_enqueued_at, )?; keep_ids_within_datetimes( rtxn, &mut batches, self.batch_finished_at, - query.after_finished_at, - query.before_finished_at, + *after_finished_at, + *before_finished_at, )?; - if let Some(limit) = query.limit { - batches = batches.into_iter().rev().take(limit as usize).collect(); + if let Some(limit) = limit { + batches = if query.reverse.unwrap_or_default() { + batches.into_iter().take(*limit as usize).collect() + } else { + batches.into_iter().rev().take(*limit as usize).collect() + }; } Ok(batches) @@ -1372,11 +1399,16 @@ impl IndexScheduler { let (batches, total) = self.get_batch_ids_from_authorized_indexes(&rtxn, &processing, &query, filters)?; + let batches = if query.reverse.unwrap_or_default() { + Box::new(batches.into_iter()) as Box> + } else { + Box::new(batches.into_iter().rev()) as Box> + }; let batches = self.get_existing_batches( &rtxn, &processing, - batches.into_iter().rev().take(query.limit.unwrap_or(u32::MAX) as usize), + batches.take(query.limit.unwrap_or(u32::MAX) as usize), )?; Ok((batches, total)) diff --git a/crates/meilisearch/tests/batches/errors.rs b/crates/meilisearch/tests/batches/errors.rs index 11f9e9b3c..2c3484bc1 100644 --- a/crates/meilisearch/tests/batches/errors.rs +++ b/crates/meilisearch/tests/batches/errors.rs @@ -114,6 +114,33 @@ async fn batch_bad_from() { "#); } +#[actix_rt::test] +async fn bask_bad_reverse() { + let server = Server::new_shared(); + + let (response, code) = server.batches_filter("reverse=doggo").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(response, @r###" + { + "message": "Invalid value in parameter `reverse`: could not parse `doggo` as a boolean, expected either `true` or `false`", + "code": "invalid_task_reverse", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_reverse" + } + "###); + + let (response, code) = server.batches_filter("reverse=*").await; + snapshot!(code, @"400 Bad Request"); + snapshot!(response, @r###" + { + "message": "Invalid value in parameter `reverse`: could not parse `*` as a boolean, expected either `true` or `false`", + "code": "invalid_task_reverse", + "type": "invalid_request", + "link": "https://docs.meilisearch.com/errors#invalid_task_reverse" + } + "###); +} + #[actix_rt::test] async fn batch_bad_after_enqueued_at() { let server = Server::new_shared(); diff --git a/crates/meilisearch/tests/batches/mod.rs b/crates/meilisearch/tests/batches/mod.rs index d715c29af..81d254f9f 100644 --- a/crates/meilisearch/tests/batches/mod.rs +++ b/crates/meilisearch/tests/batches/mod.rs @@ -49,6 +49,44 @@ async fn list_batches() { assert_eq!(response["results"].as_array().unwrap().len(), 2); } +#[actix_rt::test] +async fn list_batches_pagination_and_reverse() { + let server = Server::new().await; + // First of all we want to create a lot of batches very quickly. The fastest way is to delete a lot of unexisting indexes + let mut last_batch = None; + for i in 0..10 { + let index = server.index(format!("test-{i}")); + last_batch = Some(index.create(None).await.0.uid()); + } + server.wait_task(last_batch.unwrap()).await; + + let (response, code) = server.batches_filter("limit=3").await; + assert_eq!(code, 200); + let results = response["results"].as_array().unwrap(); + let batch_ids: Vec<_> = results.iter().map(|ret| ret["uid"].as_u64().unwrap()).collect(); + snapshot!(format!("{batch_ids:?}"), @"[9, 8, 7]"); + + let (response, code) = server.batches_filter("limit=3&from=1").await; + assert_eq!(code, 200); + let results = response["results"].as_array().unwrap(); + let batch_ids: Vec<_> = results.iter().map(|ret| ret["uid"].as_u64().unwrap()).collect(); + snapshot!(format!("{batch_ids:?}"), @"[1, 0]"); + + // In reversed order + + let (response, code) = server.batches_filter("limit=3&reverse=true").await; + assert_eq!(code, 200); + let results = response["results"].as_array().unwrap(); + let batch_ids: Vec<_> = results.iter().map(|ret| ret["uid"].as_u64().unwrap()).collect(); + snapshot!(format!("{batch_ids:?}"), @"[0, 1, 2]"); + + let (response, code) = server.batches_filter("limit=3&from=8&reverse=true").await; + assert_eq!(code, 200); + let results = response["results"].as_array().unwrap(); + let batch_ids: Vec<_> = results.iter().map(|ret| ret["uid"].as_u64().unwrap()).collect(); + snapshot!(format!("{batch_ids:?}"), @"[8, 9]"); +} + #[actix_rt::test] async fn list_batches_with_star_filters() { let server = Server::new().await; From 83d1f858c14bb7fe3a60db8b195b12840d291b9f Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 14:36:05 +0100 Subject: [PATCH 21/22] Update crates/index-scheduler/src/lib.rs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Clément Renault --- crates/index-scheduler/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/index-scheduler/src/lib.rs b/crates/index-scheduler/src/lib.rs index 083363c95..fe1bcc3d2 100644 --- a/crates/index-scheduler/src/lib.rs +++ b/crates/index-scheduler/src/lib.rs @@ -802,7 +802,7 @@ impl IndexScheduler { if let Some(batch_uids) = batch_uids { let mut batch_tasks = RoaringBitmap::new(); for batch_uid in batch_uids { - if Some(*batch_uid) == processing_batch.as_ref().map(|batch| batch.uid) { + if processing_batch.as_ref().map_or(false, |batch| batch.uid == *batch_uid) { batch_tasks |= &processing_tasks; } else { batch_tasks |= self.tasks_in_batch(rtxn, *batch_uid)?; From ec06879d28838bae678052adc1b0cbf7f718b42b Mon Sep 17 00:00:00 2001 From: Tamo Date: Wed, 20 Nov 2024 14:40:36 +0100 Subject: [PATCH 22/22] apply review changes --- crates/index-scheduler/src/batch.rs | 10 +++++----- crates/index-scheduler/src/utils.rs | 11 ++++++----- 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/crates/index-scheduler/src/batch.rs b/crates/index-scheduler/src/batch.rs index 8d6d3e49b..96f8c1cd0 100644 --- a/crates/index-scheduler/src/batch.rs +++ b/crates/index-scheduler/src/batch.rs @@ -282,7 +282,7 @@ impl IndexScheduler { match batch { BatchKind::DocumentClear { ids } => Ok(Some(Batch::IndexOperation { op: IndexOperation::DocumentClear { - tasks: self.get_existing_tasks_with_processing_batch( + tasks: self.get_existing_tasks_for_processing_batch( rtxn, current_batch, ids, @@ -308,7 +308,7 @@ impl IndexScheduler { } } BatchKind::DocumentOperation { method, operation_ids, .. } => { - let tasks = self.get_existing_tasks_with_processing_batch( + let tasks = self.get_existing_tasks_for_processing_batch( rtxn, current_batch, operation_ids, @@ -359,7 +359,7 @@ impl IndexScheduler { })) } BatchKind::DocumentDeletion { deletion_ids, includes_by_filter: _ } => { - let tasks = self.get_existing_tasks_with_processing_batch( + let tasks = self.get_existing_tasks_for_processing_batch( rtxn, current_batch, deletion_ids, @@ -371,7 +371,7 @@ impl IndexScheduler { })) } BatchKind::Settings { settings_ids, .. } => { - let tasks = self.get_existing_tasks_with_processing_batch( + let tasks = self.get_existing_tasks_for_processing_batch( rtxn, current_batch, settings_ids, @@ -520,7 +520,7 @@ impl IndexScheduler { BatchKind::IndexDeletion { ids } => Ok(Some(Batch::IndexDeletion { index_uid, index_has_been_created: must_create_index, - tasks: self.get_existing_tasks_with_processing_batch(rtxn, current_batch, ids)?, + tasks: self.get_existing_tasks_for_processing_batch(rtxn, current_batch, ids)?, })), BatchKind::IndexSwap { id } => { let mut task = self.get_task(rtxn, id)?.ok_or(Error::CorruptedTaskQueue)?; diff --git a/crates/index-scheduler/src/utils.rs b/crates/index-scheduler/src/utils.rs index 827cdf95e..08459aa2c 100644 --- a/crates/index-scheduler/src/utils.rs +++ b/crates/index-scheduler/src/utils.rs @@ -211,9 +211,10 @@ impl IndexScheduler { Ok(()) } - /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a - /// `CorruptedTaskQueue` error will be throwed. - pub(crate) fn get_existing_tasks_with_processing_batch( + /// Convert an iterator to a `Vec` of tasks and edit the `ProcessingBatch` to add the given tasks. + /// + /// The tasks MUST exist, or a `CorruptedTaskQueue` error will be thrown. + pub(crate) fn get_existing_tasks_for_processing_batch( &self, rtxn: &RoTxn, processing_batch: &mut ProcessingBatch, @@ -232,7 +233,7 @@ impl IndexScheduler { } /// Convert an iterator to a `Vec` of tasks. The tasks MUST exist or a - /// `CorruptedTaskQueue` error will be throwed. + /// `CorruptedTaskQueue` error will be thrown. pub(crate) fn get_existing_tasks( &self, rtxn: &RoTxn, @@ -247,7 +248,7 @@ impl IndexScheduler { } /// Convert an iterator to a `Vec` of batches. The batches MUST exist or a - /// `CorruptedTaskQueue` error will be throwed. + /// `CorruptedTaskQueue` error will be thrown. pub(crate) fn get_existing_batches( &self, rtxn: &RoTxn,