pub struct DecodeLimits { /* private fields */ }Expand description
Resource limits applied while decoding broker responses.
Implementations§
Source§impl DecodeLimits
impl DecodeLimits
Sourcepub const DEFAULT_MAX_ARRAY_ELEMENTS: usize = 1_000_000
pub const DEFAULT_MAX_ARRAY_ELEMENTS: usize = 1_000_000
Default maximum number of elements in one decoded Kafka array.
Sourcepub const DEFAULT_MAX_DECOMPRESSED_RECORD_BYTES: usize
pub const DEFAULT_MAX_DECOMPRESSED_RECORD_BYTES: usize
Default maximum uncompressed size of one Kafka record batch.
Sourcepub const fn with_max_array_elements(self, max: usize) -> Self
pub const fn with_max_array_elements(self, max: usize) -> Self
Sets the maximum number of elements in one decoded Kafka array.
Sourcepub const fn with_max_decompressed_record_bytes(self, max: usize) -> Self
pub const fn with_max_decompressed_record_bytes(self, max: usize) -> Self
Sets the maximum uncompressed size of one Kafka record batch.
Sourcepub const fn max_array_elements(self) -> usize
pub const fn max_array_elements(self) -> usize
Returns the maximum number of elements in one decoded Kafka array.
Sourcepub const fn max_decompressed_record_bytes(self) -> usize
pub const fn max_decompressed_record_bytes(self) -> usize
Returns the maximum uncompressed size of one Kafka record batch.
Trait Implementations§
Source§impl Clone for DecodeLimits
impl Clone for DecodeLimits
Source§fn clone(&self) -> DecodeLimits
fn clone(&self) -> DecodeLimits
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 DecodeLimits
Source§impl Debug for DecodeLimits
impl Debug for DecodeLimits
Source§impl Default for DecodeLimits
impl Default for DecodeLimits
impl Eq for DecodeLimits
Source§impl PartialEq for DecodeLimits
impl PartialEq for DecodeLimits
impl StructuralPartialEq for DecodeLimits
Auto Trait Implementations§
impl Freeze for DecodeLimits
impl RefUnwindSafe for DecodeLimits
impl Send for DecodeLimits
impl Sync for DecodeLimits
impl Unpin for DecodeLimits
impl UnsafeUnpin for DecodeLimits
impl UnwindSafe for DecodeLimits
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