#[non_exhaustive]pub enum GraphError {
Show 23 variants
NodeNotFound {
id: NodeId,
},
EdgeNotFound {
id: EdgeId,
},
NodeNotAlive {
id: NodeId,
},
EdgeNotAlive {
id: EdgeId,
},
RowSpaceExhausted {
kind: &'static str,
rows: u64,
max_rows: u64,
},
Inconsistent {
reason: String,
},
PropertyIndexAlreadyExists {
label: DbString,
property: DbString,
},
PropertyIndexNotFound {
label: DbString,
property: DbString,
},
IndexValueRejected {
label: DbString,
property: DbString,
expected_kind: TypedIndexKind,
observed: &'static str,
},
CompositePropertyIndexAlreadyExists {
label: DbString,
properties: Box<SmallVec<[DbString; 4]>>,
},
VectorIndexAlreadyExists {
label: DbString,
property: DbString,
},
VectorIndexInvalidDimension {
dimension: u32,
},
VectorIndexInvalidHnswConfig {
max_neighbors: u16,
ef_construction: u16,
reason: &'static str,
},
VectorIndexInvalidIvfConfig {
target_centroids: u16,
reason: &'static str,
},
VectorIndexValueRejected {
label: DbString,
property: DbString,
expected_dimension: u32,
observed: String,
},
TextIndexAlreadyExists {
label: DbString,
property: DbString,
},
TypeViolation(TypeViolation),
StoreAssignment(Box<StoreAssignmentError>),
Durable {
reason: String,
},
Cancelled,
Core(CoreError),
Provider(ProviderError),
Persist(PersistError),
}Expand description
Error type for graph storage and mutation operations.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NodeNotFound
The requested node row does not exist.
EdgeNotFound
The requested edge row does not exist.
NodeNotAlive
The requested node row exists but is not alive.
EdgeNotAlive
The requested edge row exists but is not alive.
RowSpaceExhausted
The dense row store filled the v1 row-addressable range (max 2^32 rows).
Post-4c the cap is a row count, not an id value: rows append at the
dense end and u32::MAX is reserved as RowIndex::TOMBSTONE, so the last
addressable row is u32::MAX - 1.
Fields
Inconsistent
The graph snapshot violates a structural invariant (e.g., row count exceeds the addressable u32 range).
PropertyIndexAlreadyExists
A property index already exists for this (label, property).
PropertyIndexNotFound
The named property index does not exist.
IndexValueRejected
A value cannot be admitted to the declared property index kind.
Fields
expected_kind: TypedIndexKindRegistered index kind.
CompositePropertyIndexAlreadyExists
A composite property index already exists for this (label, properties...).
Fields
properties: Box<SmallVec<[DbString; 4]>>Indexed property keys in declaration order.
Boxed so this variant does not inflate GraphError past clippy’s
result_large_err byte threshold: an inline SmallVec<[DbString; 4]>
is ~104 B (four owned string values plus header), and the variant
otherwise drives every GraphResult<T> stack slot over the limit.
The Box pushes the allocation onto the cold error-construction
path.
VectorIndexAlreadyExists
A vector property index already exists for this (label, property).
VectorIndexInvalidDimension
A vector index was declared with an invalid dimensionality.
VectorIndexInvalidHnswConfig
A vector index was declared with invalid HNSW construction parameters.
Fields
VectorIndexInvalidIvfConfig
A vector index was declared with invalid IVF construction parameters.
Fields
VectorIndexValueRejected
A value cannot be admitted to a vector index.
Fields
TextIndexAlreadyExists
A text index already exists for this (label, property).
TypeViolation(TypeViolation)
A closed graph mutation violates its bound graph type.
StoreAssignment(Box<StoreAssignmentError>)
A store assignment failed before the graph mutation was applied.
Durable
A commit-critical durable provider rejected or failed a write.
Cancelled
The commit was cancelled at the pre-WAL cut-line (BRIEF-117): the committer observed the cancellation token set before it appended the commit to the WAL, so nothing was persisted or published. Past the WAL append a commit is irrevocable and this is never returned.
Core(CoreError)
Error propagated from selene-core.
Provider(ProviderError)
Error propagated from an index provider.
Persist(PersistError)
Error propagated from persistence recovery.
Implementations§
Trait Implementations§
Source§impl Debug for GraphError
impl Debug for GraphError
Source§impl Diagnostic for GraphError
impl Diagnostic for GraphError
Source§fn code(&self) -> Option<Box<dyn Display + '_>>
fn code(&self) -> Option<Box<dyn Display + '_>>
Diagnostic. Ideally also globally unique, and documented
in the toplevel crate’s documentation for easy searching. Rust path
format (foo::bar::baz) is recommended, but more classic codes like
E0123 or enums will work just fine.Source§fn help(&self) -> Option<Box<dyn Display + '_>>
fn help(&self) -> Option<Box<dyn Display + '_>>
Diagnostic. Do you have any
advice for the poor soul who’s just run into this issue?Source§fn severity(&self) -> Option<Severity>
fn severity(&self) -> Option<Severity>
ReportHandlers to change the display format
of this diagnostic. Read moreSource§fn labels(&self) -> Option<Box<dyn Iterator<Item = LabeledSpan> + '_>>
fn labels(&self) -> Option<Box<dyn Iterator<Item = LabeledSpan> + '_>>
Diagnostic’s Diagnostic::source_codeSource§fn source_code(&self) -> Option<&dyn SourceCode>
fn source_code(&self) -> Option<&dyn SourceCode>
Diagnostic’s Diagnostic::labels to.Diagnostics.Source§fn url(&self) -> Option<Box<dyn Display + '_>>
fn url(&self) -> Option<Box<dyn Display + '_>>
Diagnostic.Source§fn diagnostic_source(&self) -> Option<&dyn Diagnostic>
fn diagnostic_source(&self) -> Option<&dyn Diagnostic>
Source§impl Display for GraphError
impl Display for GraphError
Source§impl Error for GraphError
impl Error for GraphError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<CoreError> for GraphError
impl From<CoreError> for GraphError
Source§impl From<GraphError> for JsonSearchError
impl From<GraphError> for JsonSearchError
Source§fn from(source: GraphError) -> Self
fn from(source: GraphError) -> Self
Source§impl From<GraphError> for TextSearchError
impl From<GraphError> for TextSearchError
Source§fn from(source: GraphError) -> Self
fn from(source: GraphError) -> Self
Source§impl From<GraphError> for VectorSearchError
impl From<GraphError> for VectorSearchError
Source§fn from(source: GraphError) -> Self
fn from(source: GraphError) -> Self
Source§impl From<PersistError> for GraphError
impl From<PersistError> for GraphError
Source§fn from(source: PersistError) -> Self
fn from(source: PersistError) -> Self
Source§impl From<ProviderError> for GraphError
impl From<ProviderError> for GraphError
Source§fn from(source: ProviderError) -> Self
fn from(source: ProviderError) -> Self
Source§impl From<TypeViolation> for GraphError
impl From<TypeViolation> for GraphError
Source§fn from(source: TypeViolation) -> Self
fn from(source: TypeViolation) -> Self
Auto Trait Implementations§
impl !RefUnwindSafe for GraphError
impl !UnwindSafe for GraphError
impl Freeze for GraphError
impl Send for GraphError
impl Sync for GraphError
impl Unpin for GraphError
impl UnsafeUnpin for GraphError
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Source§impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
Source§unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
Source§fn resolve_niched(out: Place<NichedOption<T, N1>>)
fn resolve_niched(out: Place<NichedOption<T, N1>>)
out indicating that a T is niched.