pub enum CollectionDataModel {
Transactional,
Queue,
Audit,
Config,
Vault,
Ephemeral,
Cache,
}Expand description
The durability model a collection declares for itself. The first five are durable models whose data must survive a single-node loss; the last two are explicitly local-eligible — losing their most recent unreplicated writes on failover is an accepted trade for lower write latency.
Variants§
Transactional
Durable transactional records — the default model for user data.
Queue
Durable work-queue collection (at-least-once delivery semantics).
Audit
Append-only audit log.
Config
Cluster/application configuration.
Vault
Secret/credential material.
Ephemeral
Explicitly ephemeral data with no durability expectation.
Cache
Cache-like data that can be rebuilt from a source of truth.
Implementations§
Source§impl CollectionDataModel
impl CollectionDataModel
Sourcepub fn is_durable(self) -> bool
pub fn is_durable(self) -> bool
true for models whose data must survive a single-node loss and so may
never silently acknowledge a write locally under declared HA intent.
Sourcepub fn allows_ephemeral_local(self) -> bool
pub fn allows_ephemeral_local(self) -> bool
true for the explicitly local-eligible models (Ephemeral, Cache)
that may opt into local commit even under declared HA intent.
pub fn label(self) -> &'static str
Trait Implementations§
Source§impl Clone for CollectionDataModel
impl Clone for CollectionDataModel
Source§fn clone(&self) -> CollectionDataModel
fn clone(&self) -> CollectionDataModel
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for CollectionDataModel
Source§impl Debug for CollectionDataModel
impl Debug for CollectionDataModel
impl Eq for CollectionDataModel
Source§impl PartialEq for CollectionDataModel
impl PartialEq for CollectionDataModel
Source§fn eq(&self, other: &CollectionDataModel) -> bool
fn eq(&self, other: &CollectionDataModel) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CollectionDataModel
Auto Trait Implementations§
impl Freeze for CollectionDataModel
impl RefUnwindSafe for CollectionDataModel
impl Send for CollectionDataModel
impl Sync for CollectionDataModel
impl Unpin for CollectionDataModel
impl UnsafeUnpin for CollectionDataModel
impl UnwindSafe for CollectionDataModel
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request