FetchRequest class

Experimental Fetch v4 request for explicitly selected partitions.

Only read-uncommitted consumption of uncompressed magic-2 batches is supported. This request does not join a consumer group or commit offsets. Low-level callers must discover partition leaders and API compatibility.

Inheritance

Constructors

FetchRequest(int replicaId, int maxWaitMs, int minBytes, List<FetchTopic> topics, {int maxBytes = 1048576})
Creates a request and validates consumer identity and byte/wait limits.

Properties

apiKey → int
Kafka Fetch API key.
final
apiVersion → int
Implemented wire version; this request always uses Fetch v4.
final
correlationId → int
finalinherited
expectsResponse → bool
no setterinherited
hashCode → int
The hash code for this object.
no setterinherited
maxBytes → int
Requested response byte limit, not a strict memory bound.
final
maxWaitMs → int
Maximum broker wait in milliseconds for minBytes to accumulate.
final
minBytes → int
Minimum desired response bytes before the broker returns early.
final
replicaId → int
Consumer identity sentinel; only -1 is accepted.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
topics → List<FetchTopic>
Topics and manually assigned partitions to fetch.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
parseResponse(List<int> bytes) → FetchResponse
Decodes a v4 response including correlation ID but excluding size prefix.
override
toBytes() → List<int>
Encodes the request including its four-byte network size prefix.
override
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited