import the update_file_store in the index-scheduler

This commit is contained in:
Tamo
2022-09-13 19:28:39 +02:00
committed by Clément Renault
parent 2afb381f95
commit 76597fc382
6 changed files with 5 additions and 277 deletions

View File

@ -4,8 +4,6 @@ use meilisearch_types::error::{Code, ErrorCode};
use meilisearch_types::internal_error;
use serde_json::Value;
use crate::update_file_store;
pub type Result<T> = std::result::Result<T, IndexError>;
#[derive(Debug, thiserror::Error)]
@ -25,23 +23,10 @@ internal_error!(
milli::heed::Error,
fst::Error,
serde_json::Error,
update_file_store::UpdateFileStoreError,
file_store::Error,
milli::documents::Error
);
/*
impl ErrorCode for IndexError {
fn error_code(&self) -> Code {
match self {
IndexError::Internal(_) => Code::Internal,
IndexError::DocumentNotFound(_) => Code::DocumentNotFound,
IndexError::Facet(e) => e.error_code(),
IndexError::Milli(e) => MilliError(e).error_code(),
}
}
}
*/
impl From<milli::UserError> for IndexError {
fn from(error: milli::UserError) -> IndexError {
IndexError::Milli(error.into())