...
{
"apiKey": 52,
"type": "request",
"listeners": ["controller"],
"name": "VoteRequest",
"validVersions": "0-1",
"flexibleVersions": "0+",
"fields": [
{ "name": "ClusterId", "type": "string", "versions": "0+",
"nullableVersions": "0+", "default": "null"},
{ "name": "Topics", "type": "[]TopicData",
"versions": "0+", "fields": [
{ "name": "TopicName", "type": "string", "versions": "0+", "entityType": "topicName",
"about": "The topic name." },
{ "name": "Partitions", "type": "[]PartitionData",
"versions": "0+", "fields": [
{ "name": "PartitionIndex", "type": "int32", "versions": "0+",
"about": "The partition index." },
{ "name": "CandidateEpochProposedEpoch", "type": "int32", "versions": "0+",
"about": "The bumpedproposed epoch of the prospective or candidate sending the request"},
{ "name": "CandidateId", "type": "int32", "versions": "0+", "entityType": "brokerId",
"about": "The ID of the voter sending the request"},
{ "name": "LastOffsetEpoch", "type": "int32", "versions": "0+",
"about": "The epoch of the last record written to the metadata log"},
{ "name": "LastOffset", "type": "int64", "versions": "0+",
"about": "The offset of the last record written to the metadata log"},
{ "name": "PreVote", "type": "boolean", "versions": "1+",
"about": "Whether the request is a PreVote request (no epoch increase) or not."}
...
}
...
Section |
---|
|
We add a new quorum state Prospective for servers which are sending Pre-Vote requests as well as new state transitions. The original (left) and new states (right) are below for comparison. Column |
---|
| * Unattached|Resigned transitions to: * Unattached: After learning of a new election with a higher epoch * Voted: After granting a vote to a candidate * Candidate: After expiration of the election timeout * Follower: After discovering a leader with an equal or larger epoch * * Voted transitions to: * Unattached: After learning of a new election with a higher epoch * Candidate: After expiration of the election timeout * * Candidate transitions to: * Unattached: After learning of a new election with a higher epoch * Candidate: After expiration of the election timeout * Leader: After receiving a majority of votes * * Leader transitions to: * Unattached: After learning of a new election with a higher epoch * Resigned: When shutting down gracefully * * Follower transitions to: * Unattached: After learning of a new election with a higher epoch * Candidate: After expiration of the fetch timeout * Follower: After discovering a leader with a larger epoch
|
Column |
---|
| * Unattached|Resigned transitions to: * Unattached: After learning of a candidate with a higher epoch (clarifying language)
* Voted: After granting a standard vote to a candidate (clarifying language)
* Prospective: After expiration of the election timeout
* Follower: After discovering a leader with an equal or larger epoch
*
* Voted transitions to: * Unattached: After learning of a candidate with a higher epoch
* Prospective: After expiration of the election timeout
* Follower: After discovering a leader with an equal or larger epoch (missed in original docs) *
* Prospective transitions to: * Unattached: After learning of a candidate with a higher epoch * Prospective: After expiration of the election timeout * Candidate: After receiving a majority of pre-votes
* Follower: After discovering a leader with an equal or larger epoch *
* Candidate transitions to: * Unattached: After learning of a candidate with a higher epoch
* Prospective: After expiration of the election timeout
* Leader: After receiving a majority of standard votes
* Follower: After discovering a leader with an equal or larger epoch (missed in original docs)
*
* Leader transitions to: * Unattached: After learning of a candidate with a higher epoch *
* Follower transitions to: * Unattached: After learning of a candidate with a higher epoch
* Prospective: After expiration of the election timeout
* Follower: After discovering a leader with a larger epoch |
|
...