Enum async_nats::jetstream::consumer::DeliverPolicy
source · #[repr(u8)]pub enum DeliverPolicy {
All,
Last,
New,
ByStartSequence {
start_sequence: u64,
},
ByStartTime {
start_time: OffsetDateTime,
},
LastPerSubject,
}
Expand description
DeliverPolicy
determines how the consumer should select the first message to deliver.
Variants§
All
All causes the consumer to receive the oldest messages still present in the system. This is the default.
Last
Last will start the consumer with the last sequence received.
New
New will only deliver new messages that are received by the JetStream
server
after the consumer is created.
ByStartSequence
ByStartSeq
will look for a defined starting sequence to the consumer’s configured opt_start_seq
parameter.
ByStartTime
ByStartTime
will select the first message with a timestamp >= to the consumer’s
configured opt_start_time
parameter.
Fields
§
start_time: OffsetDateTime
LastPerSubject
LastPerSubject
will start the consumer with the last message
for all subjects received.
Trait Implementations§
source§impl Clone for DeliverPolicy
impl Clone for DeliverPolicy
source§fn clone(&self) -> DeliverPolicy
fn clone(&self) -> DeliverPolicy
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for DeliverPolicy
impl Debug for DeliverPolicy
source§impl Default for DeliverPolicy
impl Default for DeliverPolicy
source§fn default() -> DeliverPolicy
fn default() -> DeliverPolicy
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for DeliverPolicy
impl<'de> Deserialize<'de> for DeliverPolicy
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for DeliverPolicy
impl PartialEq for DeliverPolicy
source§impl Serialize for DeliverPolicy
impl Serialize for DeliverPolicy
impl Copy for DeliverPolicy
impl Eq for DeliverPolicy
impl StructuralPartialEq for DeliverPolicy
Auto Trait Implementations§
impl Freeze for DeliverPolicy
impl RefUnwindSafe for DeliverPolicy
impl Send for DeliverPolicy
impl Sync for DeliverPolicy
impl Unpin for DeliverPolicy
impl UnwindSafe for DeliverPolicy
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)