mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-26 03:55:07 +08:00
log when meilisearch need to delete tasks
This commit is contained in:
parent
f9ddd32545
commit
972bb2831c
@ -1115,10 +1115,16 @@ impl IndexScheduler {
|
||||
// /!\ the len must be at least 2 or else we might enter an infinite loop where we only delete
|
||||
// the deletion tasks we enqueued ourselves.
|
||||
if to_delete.len() < 2 {
|
||||
log::warn!("The task queue is almost full, but no task can be deleted yet.");
|
||||
// the only thing we can do is hope that the user tasks are going to finish
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
log::info!(
|
||||
"The task queue is almost full. Thus, meilisearch will delete the last {} finished tasks.",
|
||||
to_delete.len()
|
||||
);
|
||||
|
||||
self.register(KindWithContent::TaskDeletion {
|
||||
query: format!(
|
||||
"?from={},limit={},status=succeeded,failed,canceled",
|
||||
|
Loading…
Reference in New Issue
Block a user