#[non_exhaustive]pub enum LaneKey {
Partition,
RecordKey,
}Expand description
What drives keyed worker lanes (workers(n, by_key)) for this subscription.
The runtime lanes deliveries by IncomingMessage::partition_key
(deliveries sharing a lane key process in order on one lane); this choice picks what that
key is for Kafka.
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.
Partition
The source partition (the default): lanes mirror Kafka’s own ordering unit, so everything a partition delivers (keyless included) processes in order on one lane.
RecordKey
The native record key: per-key ordering, finer than a partition, so messages of one partition may process concurrently when their keys differ. Keyless deliveries carry no lane key and rotate across lanes, losing their partition order.
Trait Implementations§
impl Copy for LaneKey
impl Eq for LaneKey
impl StructuralPartialEq for LaneKey
Auto Trait Implementations§
impl Freeze for LaneKey
impl RefUnwindSafe for LaneKey
impl Send for LaneKey
impl Sync for LaneKey
impl Unpin for LaneKey
impl UnsafeUnpin for LaneKey
impl UnwindSafe for LaneKey
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