What is Heartbeat?
Classic-protocol consumers send this on a fixed interval to prove liveness to the group coordinator. Missing a heartbeat within session.timeout.ms kicks the member and triggers a rebalance, usually because consumers spend too long in poll() processing, starving the heartbeat thread.
Wire Diagram
Request Header
message_size
int32 · 4B
api_key
int16 · 2B
api_version
int16 · 2B
correlation_id
int32 · 4B
client_id
string
HeartbeatRequest v0
GroupId
string
GenerationId
int32 · 4B
MemberId
string
Schema & Example
Schema { "GroupId": string, "GenerationId": int32, "MemberId": string }
Example { "GroupId": "order-processors", "GenerationId": 5, "MemberId": "consumer-1-abc123" }