#[non_exhaustive]pub struct PartitionProduceResponse {
pub index: i32,
pub error_code: i16,
pub base_offset: i64,
pub log_append_time_ms: i64,
pub log_start_offset: i64,
pub record_errors: Vec<BatchIndexAndErrorMessage>,
pub error_message: Option<StrBytes>,
pub current_leader: LeaderIdAndEpoch,
pub unknown_tagged_fields: BTreeMap<i32, Bytes>,
}Expand description
Valid versions: 0-10
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.index: i32The partition index.
Supported API versions: 0-10
error_code: i16The error code, or 0 if there was no error.
Supported API versions: 0-10
base_offset: i64The base offset.
Supported API versions: 0-10
log_append_time_ms: i64The timestamp returned by broker after appending the messages. If CreateTime is used for the topic, the timestamp will be -1. If LogAppendTime is used for the topic, the timestamp will be the broker local time when the messages are appended.
Supported API versions: 2-10
log_start_offset: i64The log start offset.
Supported API versions: 5-10
record_errors: Vec<BatchIndexAndErrorMessage>The batch indices of records that caused the batch to be dropped
Supported API versions: 8-10
error_message: Option<StrBytes>The global error message summarizing the common root cause of the records that caused the batch to be dropped
Supported API versions: 8-10
current_leader: LeaderIdAndEpochSupported API versions: 10
unknown_tagged_fields: BTreeMap<i32, Bytes>Other tagged fields
Implementations§
source§impl PartitionProduceResponse
impl PartitionProduceResponse
sourcepub fn with_index(self, value: i32) -> Self
pub fn with_index(self, value: i32) -> Self
Sets index to the passed value.
The partition index.
Supported API versions: 0-10
sourcepub fn with_error_code(self, value: i16) -> Self
pub fn with_error_code(self, value: i16) -> Self
Sets error_code to the passed value.
The error code, or 0 if there was no error.
Supported API versions: 0-10
sourcepub fn with_base_offset(self, value: i64) -> Self
pub fn with_base_offset(self, value: i64) -> Self
Sets base_offset to the passed value.
The base offset.
Supported API versions: 0-10
sourcepub fn with_log_append_time_ms(self, value: i64) -> Self
pub fn with_log_append_time_ms(self, value: i64) -> Self
Sets log_append_time_ms to the passed value.
The timestamp returned by broker after appending the messages. If CreateTime is used for the topic, the timestamp will be -1. If LogAppendTime is used for the topic, the timestamp will be the broker local time when the messages are appended.
Supported API versions: 2-10
sourcepub fn with_log_start_offset(self, value: i64) -> Self
pub fn with_log_start_offset(self, value: i64) -> Self
Sets log_start_offset to the passed value.
The log start offset.
Supported API versions: 5-10
sourcepub fn with_record_errors(self, value: Vec<BatchIndexAndErrorMessage>) -> Self
pub fn with_record_errors(self, value: Vec<BatchIndexAndErrorMessage>) -> Self
Sets record_errors to the passed value.
The batch indices of records that caused the batch to be dropped
Supported API versions: 8-10
sourcepub fn with_error_message(self, value: Option<StrBytes>) -> Self
pub fn with_error_message(self, value: Option<StrBytes>) -> Self
Sets error_message to the passed value.
The global error message summarizing the common root cause of the records that caused the batch to be dropped
Supported API versions: 8-10
sourcepub fn with_current_leader(self, value: LeaderIdAndEpoch) -> Self
pub fn with_current_leader(self, value: LeaderIdAndEpoch) -> Self
Sets current_leader to the passed value.
Supported API versions: 10
sourcepub fn with_unknown_tagged_fields(self, value: BTreeMap<i32, Bytes>) -> Self
pub fn with_unknown_tagged_fields(self, value: BTreeMap<i32, Bytes>) -> Self
Sets unknown_tagged_fields to the passed value.
sourcepub fn with_unknown_tagged_field(self, key: i32, value: Bytes) -> Self
pub fn with_unknown_tagged_field(self, key: i32, value: Bytes) -> Self
Inserts an entry into unknown_tagged_fields.
Trait Implementations§
source§impl Clone for PartitionProduceResponse
impl Clone for PartitionProduceResponse
source§fn clone(&self) -> PartitionProduceResponse
fn clone(&self) -> PartitionProduceResponse
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PartitionProduceResponse
impl Debug for PartitionProduceResponse
source§impl Decodable for PartitionProduceResponse
impl Decodable for PartitionProduceResponse
source§impl Default for PartitionProduceResponse
impl Default for PartitionProduceResponse
source§impl Encodable for PartitionProduceResponse
impl Encodable for PartitionProduceResponse
source§impl Message for PartitionProduceResponse
impl Message for PartitionProduceResponse
source§const VERSIONS: VersionRange = _
const VERSIONS: VersionRange = _
source§const DEPRECATED_VERSIONS: Option<VersionRange> = None
const DEPRECATED_VERSIONS: Option<VersionRange> = None
source§impl PartialEq for PartitionProduceResponse
impl PartialEq for PartitionProduceResponse
impl StructuralPartialEq for PartitionProduceResponse
Auto Trait Implementations§
impl !Freeze for PartitionProduceResponse
impl RefUnwindSafe for PartitionProduceResponse
impl Send for PartitionProduceResponse
impl Sync for PartitionProduceResponse
impl Unpin for PartitionProduceResponse
impl UnwindSafe for PartitionProduceResponse
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit)