Skip to content

Commit

Permalink
kvserverpb: add admitted vectors to raft request/batch
Browse files Browse the repository at this point in the history
Epic: none
Release note: none
  • Loading branch information
pav-kv committed Sep 4, 2024
1 parent b30d91b commit 8fc31ce
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion pkg/kv/kvserver/kvserverpb/raft.proto
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,15 @@ message RaftMessageRequest {
// priority of the Entries in the Message are overridden to be
// raftpb.LowPri.
bool low_priority_override = 13;
// AdmittedState annotates a MsgAppResp message with a vector of admitted log
// indices. Used only with RACv2.
kv.kvserver.kvflowcontrol.kvflowcontrolpb.AdmittedState admitted_state = 14 [(gogoproto.nullable) = false];

// AdmittedResponse is used in RACv2, for piggybacking MsgAppResp messages
// from a follower to a leader, that advance admitted for a follower.
repeated kv.kvserver.kvflowcontrol.kvflowcontrolpb.AdmittedResponseForRange admitted_response = 14 [(gogoproto.nullable) = false];
//
// TODO(pav-kv): remove.
repeated kv.kvserver.kvflowcontrol.kvflowcontrolpb.AdmittedResponseForRange admitted_response = 15 [(gogoproto.nullable) = false];
reserved 10;
}

Expand Down Expand Up @@ -153,6 +158,10 @@ message RaftMessageRequestBatch {
// provide a disjointness guarantee to leader leases.
util.hlc.Timestamp now = 3 [(gogoproto.nullable) = false,
(gogoproto.casttype) = "github.com/cockroachdb/cockroach/pkg/util/hlc.ClockTimestamp"];

// AdmittedStates contains admitted vector messages addressed to replicas
// located on the receiver node of this batch.
repeated kv.kvserver.kvflowcontrol.kvflowcontrolpb.PiggybackedAdmittedState admitted_states = 4 [(gogoproto.nullable) = false];
}

message RaftMessageResponseUnion {
Expand Down

0 comments on commit 8fc31ce

Please sign in to comment.