conduktor.io ↗

Kafka LeaveGroup Response Wire Format v0 — Binary Protocol Layout

What is LeaveGroup?

Sent on clean consumer shutdown to trigger an immediate rebalance rather than waiting for the session timeout. Without it, a departed consumer's partitions stay unassigned for up to session.timeout.ms. Static membership (group.instance.id) avoids rebalances on short restarts by skipping LeaveGroup semantics.

Related Errors

COORDINATOR_NOT_AVAILABLE · GROUP_AUTHORIZATION_FAILED · INVALID_GROUP_ID · UNKNOWN_MEMBER_ID

Wire Diagram

Response Header
message_size int32 · 4B
correlation_id int32 · 4B
LeaveGroupResponse v0
ErrorCode int16 · 2B

Schema & Example

Schema
{
  "ErrorCode": int16
}
Example
{
  "ErrorCode": 0
}