#[non_exhaustive]pub enum RedisGroupPosition {
Beginning,
End,
After(EntryId),
}Expand description
Where a consumer group’s cursor sits, for RedisGroupSeeker::seek and the
start_at(..) clause of #[subscriber].
The cursor is group-wide: it belongs to the consumer group, not to one subscription, so moving it moves it for every consumer reading that group.
§Examples
use ruststream_fred::{EntryId, RedisGroupPosition};
let replay_all = RedisGroupPosition::beginning();
let skip_backlog = RedisGroupPosition::end();
let resume = RedisGroupPosition::after("1700000000000-4".parse::<EntryId>()?);Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Beginning
The oldest entry the stream still retains: the group replays everything it holds.
End
The tail: only entries added after the seek are delivered.
After(EntryId)
The first entry after id. The cursor is exclusive, exactly like the id argument of
XGROUP SETID, so the entry at id itself is not delivered again.
Implementations§
Trait Implementations§
Source§impl Clone for RedisGroupPosition
impl Clone for RedisGroupPosition
Source§fn clone(&self) -> RedisGroupPosition
fn clone(&self) -> RedisGroupPosition
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for RedisGroupPosition
Source§impl Debug for RedisGroupPosition
impl Debug for RedisGroupPosition
impl Eq for RedisGroupPosition
Source§impl PartialEq for RedisGroupPosition
impl PartialEq for RedisGroupPosition
impl StructuralPartialEq for RedisGroupPosition
Auto Trait Implementations§
impl Freeze for RedisGroupPosition
impl RefUnwindSafe for RedisGroupPosition
impl Send for RedisGroupPosition
impl Sync for RedisGroupPosition
impl Unpin for RedisGroupPosition
impl UnsafeUnpin for RedisGroupPosition
impl UnwindSafe for RedisGroupPosition
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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