pub struct BatchingConfig {
pub max_batch_size: u16,
pub max_batch_bytes: u16,
pub max_delay_ms: u16,
}Available on crate feature
extensions only.Expand description
Batching extension configuration
Fields§
§max_batch_size: u16Maximum number of updates per batch
max_batch_bytes: u16Maximum total payload bytes per batch
max_delay_ms: u16Maximum time to hold updates for batching
Implementations§
Source§impl BatchingConfig
impl BatchingConfig
Sourcepub fn low_latency() -> Self
pub fn low_latency() -> Self
Create config optimized for low latency (smaller batches, shorter delays)
Sourcepub fn high_throughput() -> Self
pub fn high_throughput() -> Self
Create config optimized for high throughput (larger batches, longer delays)
Sourcepub fn to_extension(&self) -> Extension
pub fn to_extension(&self) -> Extension
Encode to extension
Sourcepub fn from_extension(ext: &Extension) -> Option<Self>
pub fn from_extension(ext: &Extension) -> Option<Self>
Decode from extension
Trait Implementations§
Source§impl Clone for BatchingConfig
impl Clone for BatchingConfig
Source§fn clone(&self) -> BatchingConfig
fn clone(&self) -> BatchingConfig
Returns a duplicate 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 BatchingConfig
impl Debug for BatchingConfig
Source§impl Default for BatchingConfig
impl Default for BatchingConfig
Source§impl PartialEq for BatchingConfig
impl PartialEq for BatchingConfig
impl Eq for BatchingConfig
impl StructuralPartialEq for BatchingConfig
Auto Trait Implementations§
impl Freeze for BatchingConfig
impl RefUnwindSafe for BatchingConfig
impl Send for BatchingConfig
impl Sync for BatchingConfig
impl Unpin for BatchingConfig
impl UnwindSafe for BatchingConfig
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