Struct kafka::client::FetchPartition
[−]
[src]
pub struct FetchPartition<'a> { pub topic: &'a str, pub offset: i64, pub partition: i32, pub max_bytes: i32, }
Partition related request data for fetching messages.
See KafkaClient::fetch_messages
.
Fields
topic: &'a str
The topic to fetch messages from.
offset: i64
The offset as of which to fetch messages.
partition: i32
The partition to fetch messasges from.
max_bytes: i32
Specifies the max. amount of data to fetch (for this partition.) This implicitely defines the biggest message the client can accept. If this value is too small, no messages can be delivered. Setting this size should be in sync with the producers to the partition.
Zero or negative values are treated as "unspecified".
Methods
impl<'a> FetchPartition<'a>
[src]
fn new(topic: &'a str, partition: i32, offset: i64) -> Self
Creates a new "fetch messages" request structure with an
unspecified max_bytes
.
fn with_max_bytes(self, max_bytes: i32) -> Self
Sets the max_bytes
value for the "fetch messages" request.
Trait Implementations
impl<'a> Debug for FetchPartition<'a>
[src]
impl<'a> AsRef<FetchPartition<'a>> for FetchPartition<'a>
[src]
fn as_ref(&self) -> &Self
Performs the conversion.