conduktor.io ↗

Kafka JoinGroup Response Wire Format v1 — Binary Protocol Layout

What is JoinGroup?

Triggers a rebalance: any new member, departing member, or subscription change causes all members to call JoinGroup and wait at a synchronization barrier. The leader (first joiner) receives all members' metadata and runs the partition assignor.

Related Errors

COORDINATOR_NOT_AVAILABLE · FENCED_INSTANCE_ID · GROUP_AUTHORIZATION_FAILED · GROUP_MAX_SIZE_REACHED · INCONSISTENT_GROUP_PROTOCOL · INVALID_GROUP_ID · INVALID_SESSION_TIMEOUT · MEMBER_ID_REQUIRED · UNKNOWN_MEMBER_ID

Wire Diagram

Response Header
message_size int32 · 4B
correlation_id int32 · 4B
JoinGroupResponse v1
ErrorCode int16 · 2B
GenerationId int32 · 4B
ProtocolName string
Leader string
MemberId string
Members array
MemberId string
Metadata bytes

Schema & Example

Schema
{
  "ErrorCode": int16,
  "GenerationId": int32,
  "ProtocolName": string,
  "Leader": string,
  "MemberId": string,
  "Members": [{
      "MemberId": string,
      "Metadata": bytes
  }]
}
Example
{
  "ErrorCode": 0,
  "GenerationId": 5,
  "ProtocolName": "range",
  "Leader": "consumer-1-abc123",
  "MemberId": "consumer-1-abc123",
  "Members": [{
      "MemberId": "consumer-1-abc123",
      "Metadata": "<metadata>"
  }]
}