mirror of
				https://github.com/meilisearch/meilisearch.git
				synced 2025-10-30 23:46:28 +00:00 
			
		
		
		
	Introduce a basic version of the InternalError struct
This commit is contained in:
		
							
								
								
									
										42
									
								
								milli/src/error.rs
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										42
									
								
								milli/src/error.rs
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,42 @@ | ||||
| use std::io; | ||||
|  | ||||
| use crate::{DocumentId, FieldId}; | ||||
|  | ||||
| pub enum Error { | ||||
|     InternalError(InternalError), | ||||
|     IoError(io::Error), | ||||
|     UserError(UserError), | ||||
| } | ||||
|  | ||||
| pub enum InternalError { | ||||
|     DatabaseMissingEntry(DatabaseMissingEntry), | ||||
|     FieldIdMapMissingEntry(FieldIdMapMissingEntry), | ||||
|     IndexingMergingKeys(IndexingMergingKeys), | ||||
| } | ||||
|  | ||||
| pub enum IndexingMergingKeys { | ||||
|     DocIdWordPosition, | ||||
|     Document, | ||||
|     MainFstDeserialization, | ||||
|     WordLevelPositionDocids, | ||||
|     WordPrefixLevelPositionDocids, | ||||
| } | ||||
|  | ||||
| pub enum FieldIdMapMissingEntry { | ||||
|     DisplayedFieldId { field_id: FieldId }, | ||||
|     DisplayedFieldName { field_name: String }, | ||||
|     FacetedFieldName { field_name: String }, | ||||
|     FilterableFieldName { field_name: String }, | ||||
|     SearchableFieldName { field_name: String }, | ||||
| } | ||||
|  | ||||
| pub enum DatabaseMissingEntry { | ||||
|     DocumentId { internal_id: DocumentId }, | ||||
|     FacetValuesDocids, | ||||
|     IndexCreationTime, | ||||
|     IndexUpdateTime, | ||||
| } | ||||
|  | ||||
| pub enum UserError { | ||||
|  | ||||
| } | ||||
| @@ -1,6 +1,7 @@ | ||||
| #[macro_use] extern crate pest_derive; | ||||
|  | ||||
| mod criterion; | ||||
| mod error; | ||||
| mod external_documents_ids; | ||||
| mod fields_ids_map; | ||||
| mod search; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user