conduktor.io ↗

Kafka BeginQuorumEpoch Response Wire Format v1 — Binary Protocol Layout

What is BeginQuorumEpoch?

The newly elected KRaft leader sends this to all quorum voters to establish itself for the new epoch. Metadata writes pending from the old epoch will be replicated or dropped based on the new leader's log end offset.

Related Errors

INCONSISTENT_VOTER_SET

Wire Diagram

Response Header · flexible
message_size int32 · 4B
correlation_id int32 · 4B
tagged var
BeginQuorumEpochResponse v1
ErrorCode int16 · 2B
Topics array
NodeEndpoints array
tagged var
TopicName string (compact)
Partitions array
tagged var
PartitionIndex int32 · 4B
ErrorCode int16 · 2B
LeaderId int32 · 4B
LeaderEpoch int32 · 4B
tagged var
NodeId int32 · 4B
Host string (compact)
Port uint16 · 2B
tagged var

Schema & Example

Schema
{
  "ErrorCode": int16,
  "Topics": [{
      "TopicName": string,
      "Partitions": [{
          "PartitionIndex": int32,
          "ErrorCode": int16,
          "LeaderId": int32,
          "LeaderEpoch": int32
      }]
  }],
  "NodeEndpoints": [{
      "NodeId": int32,
      "Host": string,
      "Port": uint16
  }]
}
Example
{
  "ErrorCode": 0,
  "Topics": [{
      "TopicName": "orders",
      "Partitions": [{
          "PartitionIndex": 3,
          "ErrorCode": 0,
          "LeaderId": 1,
          "LeaderEpoch": 17
      }]
  }],
  "NodeEndpoints": [{
      "NodeId": 1,
      "Host": "broker-1.kafka.local",
      "Port": 9092
  }]
}