confluent-kafka-dotnet
Show / Hide Table of Contents

Class ConsumeResult<TKey, TValue>

Represents a message consumed from a Kafka cluster.

Inheritance
object
ConsumeResult<TKey, TValue>
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Confluent.Kafka
Assembly: Confluent.Kafka.dll
Syntax
public class ConsumeResult<TKey, TValue>
Type Parameters
Name Description
TKey
TValue

Properties

Headers

The Kafka message headers.

Declaration
[Obsolete("Please access the message Headers via .Message.Headers.")]
public Headers Headers { get; }
Property Value
Type Description
Headers

IsPartitionEOF

True if this instance represents an end of partition event, false if it represents a message in kafka.

Declaration
public bool IsPartitionEOF { get; set; }
Property Value
Type Description
bool

Key

The Kafka message Key.

Declaration
[Obsolete("Please access the message Key via .Message.Key.")]
public TKey Key { get; }
Property Value
Type Description
TKey

LeaderEpoch

The offset leader epoch (optional).

Declaration
public int? LeaderEpoch { get; set; }
Property Value
Type Description
int?

Message

The Kafka message, or null if this ConsumeResult instance represents an end of partition event.

Declaration
public Message<TKey, TValue> Message { get; set; }
Property Value
Type Description
Message<TKey, TValue>

Offset

The partition offset associated with the message.

Declaration
public Offset Offset { get; set; }
Property Value
Type Description
Offset

Partition

The partition associated with the message.

Declaration
public Partition Partition { get; set; }
Property Value
Type Description
Partition

Timestamp

The Kafka message timestamp.

Declaration
[Obsolete("Please access the message Timestamp via .Message.Timestamp.")]
public Timestamp Timestamp { get; }
Property Value
Type Description
Timestamp

Topic

The topic associated with the message.

Declaration
public string Topic { get; set; }
Property Value
Type Description
string

TopicPartition

The TopicPartition associated with the message.

Declaration
public TopicPartition TopicPartition { get; }
Property Value
Type Description
TopicPartition

TopicPartitionOffset

The TopicPartitionOffset associated with the message.

Declaration
public TopicPartitionOffset TopicPartitionOffset { get; set; }
Property Value
Type Description
TopicPartitionOffset

Value

The Kafka message Value.

Declaration
[Obsolete("Please access the message Value via .Message.Value.")]
public TValue Value { get; }
Property Value
Type Description
TValue
In this article