conduktor.io ↗

Kafka LeaveGroup Changelog — Protocol Version History

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.

VersionKafkaChanges
LeaveGroupRequest
v02.2
+ GroupId string
+ MemberId string
v12.2
are the same as version 0.
v22.2
are the same as version 0.
v32.4
+ Members []MemberIdentity
+ MemberId string
+ GroupInstanceId string
- MemberId string
defines batch processing scheme with group.instance.id + member.id for identity
v42.4
~ Flexible encoding enabled FLEXIBLE
is the first flexible version.
v53.2
+ Reason string
adds the Reason field (KIP-800).
LeaveGroupResponse
v02.2
+ ErrorCode int16
v12.2
+ ThrottleTimeMs int32
adds the throttle time.
v22.2
on quota violation, brokers send out responses before throttling.
v32.4
+ Members []MemberResponse
+ MemberId string
+ GroupInstanceId string
+ ErrorCode int16
we will make leave group request into batch mode and add group.instance.id.
v42.4
~ Flexible encoding enabled FLEXIBLE
is the first flexible version.
v53.2
is the same as version 4.