pub struct PartitionedMessageBuilder<'a, P: ProducerApi = Producer> { /* private fields */ }Expand description
Partitioned-producer-bound counterpart to crate::MessageBuilder. Same chained
setters; the terminal .send().await resolves the partition and dispatches.
Implementations§
Source§impl<P: ProducerApi> PartitionedMessageBuilder<'_, P>
impl<P: ProducerApi> PartitionedMessageBuilder<'_, P>
Sourcepub fn key(self, key: impl Into<String>) -> Self
pub fn key(self, key: impl Into<String>) -> Self
See OutgoingMessage::key.
Sourcepub fn ordering_key(self, key: impl Into<Bytes>) -> Self
pub fn ordering_key(self, key: impl Into<Bytes>) -> Self
Sourcepub fn event_time_ms(self, ts: u64) -> Self
pub fn event_time_ms(self, ts: u64) -> Self
Sourcepub fn deliver_at_ms(self, ts_ms: i64) -> Self
pub fn deliver_at_ms(self, ts_ms: i64) -> Self
Sourcepub fn deliver_after_ms(self, now_ms: i64, delay_ms: i64) -> Self
pub fn deliver_after_ms(self, now_ms: i64, delay_ms: i64) -> Self
See OutgoingMessage::deliver_after_ms. The caller supplies
now_ms (sans-io, ADR-0011 invariant #3).
Sourcepub fn replication_clusters(self, clusters: Vec<String>) -> Self
pub fn replication_clusters(self, clusters: Vec<String>) -> Self
Sourcepub fn disable_replication(self) -> Self
pub fn disable_replication(self) -> Self
Sourcepub fn txn(self, txn_id: TxnId) -> Self
pub fn txn(self, txn_id: TxnId) -> Self
See OutgoingMessage::txn.
Sourcepub fn value(self, payload: impl Into<Bytes>) -> Self
pub fn value(self, payload: impl Into<Bytes>) -> Self
Set the payload bytes. See OutgoingMessage::value.
Trait Implementations§
Auto Trait Implementations§
impl<'a, P = Producer> !Freeze for PartitionedMessageBuilder<'a, P>
impl<'a, P = Producer> !RefUnwindSafe for PartitionedMessageBuilder<'a, P>
impl<'a, P = Producer> !UnwindSafe for PartitionedMessageBuilder<'a, P>
impl<'a, P> Send for PartitionedMessageBuilder<'a, P>where
&'a PartitionedProducer<P>: Send,
impl<'a, P> Sync for PartitionedMessageBuilder<'a, P>where
&'a PartitionedProducer<P>: Sync,
impl<'a, P> Unpin for PartitionedMessageBuilder<'a, P>where
&'a PartitionedProducer<P>: Unpin,
impl<'a, P> UnsafeUnpin for PartitionedMessageBuilder<'a, P>where
&'a PartitionedProducer<P>: UnsafeUnpin,
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