KIP-951 — Leader discovery optimizations for the client
Accepted Kafka 3.7 ProtocolClient
Embeds new leader information (leader ID, epoch, host/port) directly in ProduceResponse and FetchResponse error payloads when a broker knows the current leader, eliminating or reducing the need for a separate Metadata RPC round-trip after a leadership change. The existing leader discovery path required an asynchronous Metadata refresh plus retry backoff before the client could resume producing or fetching, significantly increasing end-to-end latency during leader elections and cluster rolls.
Protocol Impact
Produce v10 · Fetch v16 · Metadata
Details
| Author | Mayank Shekhar Narula |
| Status | Accepted |
| Kafka Version | 3.7 |
| JIRA | KAFKA-15868 |
| Wiki | View on Apache Wiki |
| Created | 2023-07-13 |
| Last Modified | 2025-07-21 |
Explore how this KIP affects the Kafka protocol in the Protocol Explorer, or see the full KIP database.