pub struct Impulse {
pub id: u64,
pub source_structure: u8,
pub source_node: [u8; 32],
pub target_structure: u8,
pub impulse_type: ImpulseType,
pub payload: Value,
pub hlc_timestamp: u64,
pub acknowledged: AtomicBool,
}Expand description
A single causal event travelling between ECC structures.
source_structure and target_structure are u8 tags that correspond to
crossref::StructureTag::as_u8() values:
0 = CausalGraph, 1 = SpectralIndex, 2 = Hnsw, 3 = CloudBridge.
Fields§
§id: u64Monotonically increasing identifier assigned by the queue.
source_structure: u8Originating structure (see StructureTag::as_u8()).
source_node: [u8; 32]32-byte universal node identifier from the source structure.
target_structure: u8Destination structure (see StructureTag::as_u8()).
impulse_type: ImpulseTypeThe kind of impulse.
payload: ValueArbitrary JSON payload carried by this impulse.
hlc_timestamp: u64Hybrid-logical-clock timestamp for causal ordering.
acknowledged: AtomicBoolSet to true once the consumer has processed this impulse.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for Impulse
impl RefUnwindSafe for Impulse
impl Send for Impulse
impl Sync for Impulse
impl Unpin for Impulse
impl UnsafeUnpin for Impulse
impl UnwindSafe for Impulse
Blanket Implementations§
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
Converts
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>
Converts
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 more