Merge pull request #12790 from nvanbenschoten/reduce-raft-proto-size

raft: disable XXX_NoUnkeyedLiteral, XXX_unrecognized, and XXX_sizecache fields in protos
release-3.5
Piotr Tabor 2021-03-27 21:08:50 +01:00 committed by GitHub
commit 578ffd5783
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 162 additions and 194 deletions

View File

@ -35,7 +35,6 @@ func (cs ConfState) Equivalent(cs2 ConfState) error {
s(&cs.Learners)
s(&cs.VotersOutgoing)
s(&cs.LearnersNext)
cs.XXX_unrecognized = nil
}
if !reflect.DeepEqual(cs1, cs2) {

View File

@ -264,13 +264,10 @@ func (ConfChangeType) EnumDescriptor() ([]byte, []int) {
}
type Entry struct {
Term uint64 `protobuf:"varint,2,opt,name=Term" json:"Term"`
Index uint64 `protobuf:"varint,3,opt,name=Index" json:"Index"`
Type EntryType `protobuf:"varint,1,opt,name=Type,enum=raftpb.EntryType" json:"Type"`
Data []byte `protobuf:"bytes,4,opt,name=Data" json:"Data,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Term uint64 `protobuf:"varint,2,opt,name=Term" json:"Term"`
Index uint64 `protobuf:"varint,3,opt,name=Index" json:"Index"`
Type EntryType `protobuf:"varint,1,opt,name=Type,enum=raftpb.EntryType" json:"Type"`
Data []byte `protobuf:"bytes,4,opt,name=Data" json:"Data,omitempty"`
}
func (m *Entry) Reset() { *m = Entry{} }
@ -307,12 +304,9 @@ func (m *Entry) XXX_DiscardUnknown() {
var xxx_messageInfo_Entry proto.InternalMessageInfo
type SnapshotMetadata struct {
ConfState ConfState `protobuf:"bytes,1,opt,name=conf_state,json=confState" json:"conf_state"`
Index uint64 `protobuf:"varint,2,opt,name=index" json:"index"`
Term uint64 `protobuf:"varint,3,opt,name=term" json:"term"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
ConfState ConfState `protobuf:"bytes,1,opt,name=conf_state,json=confState" json:"conf_state"`
Index uint64 `protobuf:"varint,2,opt,name=index" json:"index"`
Term uint64 `protobuf:"varint,3,opt,name=term" json:"term"`
}
func (m *SnapshotMetadata) Reset() { *m = SnapshotMetadata{} }
@ -349,11 +343,8 @@ func (m *SnapshotMetadata) XXX_DiscardUnknown() {
var xxx_messageInfo_SnapshotMetadata proto.InternalMessageInfo
type Snapshot struct {
Data []byte `protobuf:"bytes,1,opt,name=data" json:"data,omitempty"`
Metadata SnapshotMetadata `protobuf:"bytes,2,opt,name=metadata" json:"metadata"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Data []byte `protobuf:"bytes,1,opt,name=data" json:"data,omitempty"`
Metadata SnapshotMetadata `protobuf:"bytes,2,opt,name=metadata" json:"metadata"`
}
func (m *Snapshot) Reset() { *m = Snapshot{} }
@ -399,17 +390,14 @@ type Message struct {
// index=101, and the term of entry at index 100 is 5.
// (type=MsgAppResp,reject=true,index=100,logTerm=5) means follower rejects some
// entries from its leader as it already has an entry with term 5 at index 100.
LogTerm uint64 `protobuf:"varint,5,opt,name=logTerm" json:"logTerm"`
Index uint64 `protobuf:"varint,6,opt,name=index" json:"index"`
Entries []Entry `protobuf:"bytes,7,rep,name=entries" json:"entries"`
Commit uint64 `protobuf:"varint,8,opt,name=commit" json:"commit"`
Snapshot Snapshot `protobuf:"bytes,9,opt,name=snapshot" json:"snapshot"`
Reject bool `protobuf:"varint,10,opt,name=reject" json:"reject"`
RejectHint uint64 `protobuf:"varint,11,opt,name=rejectHint" json:"rejectHint"`
Context []byte `protobuf:"bytes,12,opt,name=context" json:"context,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
LogTerm uint64 `protobuf:"varint,5,opt,name=logTerm" json:"logTerm"`
Index uint64 `protobuf:"varint,6,opt,name=index" json:"index"`
Entries []Entry `protobuf:"bytes,7,rep,name=entries" json:"entries"`
Commit uint64 `protobuf:"varint,8,opt,name=commit" json:"commit"`
Snapshot Snapshot `protobuf:"bytes,9,opt,name=snapshot" json:"snapshot"`
Reject bool `protobuf:"varint,10,opt,name=reject" json:"reject"`
RejectHint uint64 `protobuf:"varint,11,opt,name=rejectHint" json:"rejectHint"`
Context []byte `protobuf:"bytes,12,opt,name=context" json:"context,omitempty"`
}
func (m *Message) Reset() { *m = Message{} }
@ -446,12 +434,9 @@ func (m *Message) XXX_DiscardUnknown() {
var xxx_messageInfo_Message proto.InternalMessageInfo
type HardState struct {
Term uint64 `protobuf:"varint,1,opt,name=term" json:"term"`
Vote uint64 `protobuf:"varint,2,opt,name=vote" json:"vote"`
Commit uint64 `protobuf:"varint,3,opt,name=commit" json:"commit"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Term uint64 `protobuf:"varint,1,opt,name=term" json:"term"`
Vote uint64 `protobuf:"varint,2,opt,name=vote" json:"vote"`
Commit uint64 `protobuf:"varint,3,opt,name=commit" json:"commit"`
}
func (m *HardState) Reset() { *m = HardState{} }
@ -501,10 +486,7 @@ type ConfState struct {
LearnersNext []uint64 `protobuf:"varint,4,rep,name=learners_next,json=learnersNext" json:"learners_next,omitempty"`
// If set, the config is joint and Raft will automatically transition into
// the final config (i.e. remove the outgoing config) when this is safe.
AutoLeave bool `protobuf:"varint,5,opt,name=auto_leave,json=autoLeave" json:"auto_leave"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
AutoLeave bool `protobuf:"varint,5,opt,name=auto_leave,json=autoLeave" json:"auto_leave"`
}
func (m *ConfState) Reset() { *m = ConfState{} }
@ -547,10 +529,7 @@ type ConfChange struct {
// NB: this is used only by etcd to thread through a unique identifier.
// Ideally it should really use the Context instead. No counterpart to
// this field exists in ConfChangeV2.
ID uint64 `protobuf:"varint,1,opt,name=id" json:"id"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
ID uint64 `protobuf:"varint,1,opt,name=id" json:"id"`
}
func (m *ConfChange) Reset() { *m = ConfChange{} }
@ -589,11 +568,8 @@ var xxx_messageInfo_ConfChange proto.InternalMessageInfo
// ConfChangeSingle is an individual configuration change operation. Multiple
// such operations can be carried out atomically via a ConfChangeV2.
type ConfChangeSingle struct {
Type ConfChangeType `protobuf:"varint,1,opt,name=type,enum=raftpb.ConfChangeType" json:"type"`
NodeID uint64 `protobuf:"varint,2,opt,name=node_id,json=nodeId" json:"node_id"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Type ConfChangeType `protobuf:"varint,1,opt,name=type,enum=raftpb.ConfChangeType" json:"type"`
NodeID uint64 `protobuf:"varint,2,opt,name=node_id,json=nodeId" json:"node_id"`
}
func (m *ConfChangeSingle) Reset() { *m = ConfChangeSingle{} }
@ -662,12 +638,9 @@ var xxx_messageInfo_ConfChangeSingle proto.InternalMessageInfo
//
// [1]: https://github.com/ongardie/dissertation/blob/master/online-trim.pdf
type ConfChangeV2 struct {
Transition ConfChangeTransition `protobuf:"varint,1,opt,name=transition,enum=raftpb.ConfChangeTransition" json:"transition"`
Changes []ConfChangeSingle `protobuf:"bytes,2,rep,name=changes" json:"changes"`
Context []byte `protobuf:"bytes,3,opt,name=context" json:"context,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Transition ConfChangeTransition `protobuf:"varint,1,opt,name=transition,enum=raftpb.ConfChangeTransition" json:"transition"`
Changes []ConfChangeSingle `protobuf:"bytes,2,rep,name=changes" json:"changes"`
Context []byte `protobuf:"bytes,3,opt,name=context" json:"context,omitempty"`
}
func (m *ConfChangeV2) Reset() { *m = ConfChangeV2{} }
@ -722,71 +695,72 @@ func init() {
func init() { proto.RegisterFile("raft.proto", fileDescriptor_b042552c306ae59b) }
var fileDescriptor_b042552c306ae59b = []byte{
// 1011 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xcd, 0x6e, 0xe3, 0x36,
0x17, 0xb5, 0x64, 0xc5, 0x3f, 0xd7, 0x8e, 0xc3, 0xdc, 0xc9, 0x37, 0x20, 0x82, 0xc0, 0xe3, 0xcf,
0xd3, 0x62, 0x8c, 0x14, 0x93, 0x16, 0x5e, 0x14, 0x45, 0x77, 0xf9, 0x19, 0x20, 0x29, 0xe2, 0x74,
0xea, 0x64, 0xb2, 0x28, 0x50, 0x04, 0x8c, 0x45, 0x2b, 0x6a, 0x2d, 0x51, 0xa0, 0xe8, 0x34, 0xd9,
0x14, 0x45, 0x9f, 0xa2, 0x9b, 0xd9, 0xf6, 0x01, 0xfa, 0x14, 0x59, 0x0e, 0xd0, 0xfd, 0xa0, 0x93,
0xbe, 0x48, 0x41, 0x8a, 0xb2, 0x65, 0x27, 0x98, 0x45, 0x77, 0xe4, 0xb9, 0x87, 0x97, 0xe7, 0xdc,
0x7b, 0x45, 0x01, 0x48, 0x36, 0x56, 0x3b, 0x89, 0x14, 0x4a, 0x60, 0x45, 0xaf, 0x93, 0xcb, 0xcd,
0x8d, 0x40, 0x04, 0xc2, 0x40, 0x9f, 0xeb, 0x55, 0x16, 0xed, 0xfe, 0x02, 0x2b, 0xaf, 0x62, 0x25,
0x6f, 0x91, 0x82, 0x77, 0xc6, 0x65, 0x44, 0xdd, 0x8e, 0xd3, 0xf3, 0xf6, 0xbc, 0xbb, 0xf7, 0xcf,
0x4a, 0x43, 0x83, 0xe0, 0x26, 0xac, 0x1c, 0xc5, 0x3e, 0xbf, 0xa1, 0xe5, 0x42, 0x28, 0x83, 0xf0,
0x33, 0xf0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 0x3e, 0x86, 0xef, 0x4e, 0x95, 0x20, 0x25, 0xfc, 0x14, 0xfe, 0xff, 0x58, 0xf4, 0x1b, 0x11,
0xc6, 0xea, 0x28, 0x4a, 0x26, 0xe1, 0x28, 0xd4, 0xad, 0xf8, 0x18, 0xed, 0xd5, 0x8d, 0xa5, 0xb9,
0xdb, 0xb7, 0xd0, 0x5a, 0xfc, 0x28, 0x74, 0x31, 0xe6, 0xc8, 0xae, 0xef, 0xeb, 0xf1, 0x27, 0x25,
0xa4, 0x45, 0xb1, 0x43, 0x1e, 0x89, 0x6b, 0x6e, 0x22, 0xce, 0x62, 0xe4, 0x4d, 0xe2, 0x33, 0x95,
0x45, 0xdc, 0x45, 0x23, 0xbb, 0xbe, 0x7f, 0x9c, 0xbd, 0x3d, 0x26, 0x5a, 0xde, 0xa3, 0x77, 0x1f,
0xda, 0xa5, 0x77, 0x1f, 0xda, 0xa5, 0xbb, 0xfb, 0xb6, 0xf3, 0xee, 0xbe, 0xed, 0xfc, 0x7d, 0xdf,
0x76, 0x7e, 0xff, 0xa7, 0x5d, 0xfa, 0x37, 0x00, 0x00, 0xff, 0xff, 0xda, 0x82, 0xb6, 0x0d, 0xaf,
0x08, 0x00, 0x00,
// 1026 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x55, 0xcd, 0x6e, 0xdb, 0x46,
0x17, 0x25, 0x29, 0x5a, 0x3f, 0x57, 0xb2, 0x3c, 0xbe, 0xf1, 0x17, 0x10, 0x86, 0xc1, 0xe8, 0x53,
0x52, 0x44, 0x70, 0x11, 0xb7, 0xd0, 0xa2, 0x28, 0xba, 0xf3, 0x4f, 0x00, 0xab, 0xb0, 0xdc, 0x54,
0x76, 0xbc, 0x28, 0x50, 0x08, 0x63, 0x71, 0x44, 0xb3, 0x15, 0x39, 0x04, 0x39, 0x72, 0xed, 0x4d,
0x51, 0xf4, 0x09, 0xba, 0xec,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x35, 0x6f, 0xef,
0x5c, 0xf3, 0x9f, 0x3b, 0xd7, 0xfc, 0xed, 0xde, 0x35, 0x7e, 0xbf, 0x77, 0x8d, 0xdb, 0x7b, 0xd7,
0xf8, 0xfb, 0xde, 0x35, 0xfe, 0x0d, 0x00, 0x00, 0xff, 0xff, 0xee, 0xe3, 0x39, 0x8b, 0xbb, 0x08,
0x00, 0x00,
}
func (m *Entry) Marshal() (dAtA []byte, err error) {
@ -809,10 +783,6 @@ func (m *Entry) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Data != nil {
i -= len(m.Data)
copy(dAtA[i:], m.Data)
@ -852,10 +822,6 @@ func (m *SnapshotMetadata) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
i = encodeVarintRaft(dAtA, i, uint64(m.Term))
i--
dAtA[i] = 0x18
@ -895,10 +861,6 @@ func (m *Snapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
{
size, err := m.Metadata.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
@ -939,10 +901,6 @@ func (m *Message) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Context != nil {
i -= len(m.Context)
copy(dAtA[i:], m.Context)
@ -1029,10 +987,6 @@ func (m *HardState) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
i = encodeVarintRaft(dAtA, i, uint64(m.Commit))
i--
dAtA[i] = 0x18
@ -1065,10 +1019,6 @@ func (m *ConfState) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
i--
if m.AutoLeave {
dAtA[i] = 1
@ -1128,10 +1078,6 @@ func (m *ConfChange) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Context != nil {
i -= len(m.Context)
copy(dAtA[i:], m.Context)
@ -1171,10 +1117,6 @@ func (m *ConfChangeSingle) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
i = encodeVarintRaft(dAtA, i, uint64(m.NodeID))
i--
dAtA[i] = 0x10
@ -1204,10 +1146,6 @@ func (m *ConfChangeV2) MarshalToSizedBuffer(dAtA []byte) (int, error) {
_ = i
var l int
_ = l
if m.XXX_unrecognized != nil {
i -= len(m.XXX_unrecognized)
copy(dAtA[i:], m.XXX_unrecognized)
}
if m.Context != nil {
i -= len(m.Context)
copy(dAtA[i:], m.Context)
@ -1259,9 +1197,6 @@ func (m *Entry) Size() (n int) {
l = len(m.Data)
n += 1 + l + sovRaft(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1275,9 +1210,6 @@ func (m *SnapshotMetadata) Size() (n int) {
n += 1 + l + sovRaft(uint64(l))
n += 1 + sovRaft(uint64(m.Index))
n += 1 + sovRaft(uint64(m.Term))
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1293,9 +1225,6 @@ func (m *Snapshot) Size() (n int) {
}
l = m.Metadata.Size()
n += 1 + l + sovRaft(uint64(l))
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1326,9 +1255,6 @@ func (m *Message) Size() (n int) {
l = len(m.Context)
n += 1 + l + sovRaft(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1341,9 +1267,6 @@ func (m *HardState) Size() (n int) {
n += 1 + sovRaft(uint64(m.Term))
n += 1 + sovRaft(uint64(m.Vote))
n += 1 + sovRaft(uint64(m.Commit))
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1374,9 +1297,6 @@ func (m *ConfState) Size() (n int) {
}
}
n += 2
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1393,9 +1313,6 @@ func (m *ConfChange) Size() (n int) {
l = len(m.Context)
n += 1 + l + sovRaft(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1407,9 +1324,6 @@ func (m *ConfChangeSingle) Size() (n int) {
_ = l
n += 1 + sovRaft(uint64(m.Type))
n += 1 + sovRaft(uint64(m.NodeID))
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1430,9 +1344,6 @@ func (m *ConfChangeV2) Size() (n int) {
l = len(m.Context)
n += 1 + l + sovRaft(uint64(l))
}
if m.XXX_unrecognized != nil {
n += len(m.XXX_unrecognized)
}
return n
}
@ -1574,7 +1485,6 @@ func (m *Entry) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -1696,7 +1606,6 @@ func (m *SnapshotMetadata) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -1814,7 +1723,6 @@ func (m *Snapshot) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2138,7 +2046,6 @@ func (m *Message) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2246,7 +2153,6 @@ func (m *HardState) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2621,7 +2527,6 @@ func (m *ConfState) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2763,7 +2668,6 @@ func (m *ConfChange) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2852,7 +2756,6 @@ func (m *ConfChangeSingle) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}
@ -2990,7 +2893,6 @@ func (m *ConfChangeV2) Unmarshal(dAtA []byte) error {
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
iNdEx += skippy
}
}

View File

@ -8,6 +8,9 @@ option (gogoproto.sizer_all) = true;
option (gogoproto.unmarshaler_all) = true;
option (gogoproto.goproto_getters_all) = false;
option (gogoproto.goproto_enum_prefix_all) = false;
option (gogoproto.goproto_unkeyed_all) = false;
option (gogoproto.goproto_unrecognized_all) = false;
option (gogoproto.goproto_sizecache_all) = false;
enum EntryType {
EntryNormal = 0;

64
raft/raftpb/raft_test.go Normal file
View File

@ -0,0 +1,64 @@
// Copyright 2021 The etcd Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package raftpb
import (
"math/bits"
"testing"
"unsafe"
)
func TestProtoMemorySizes(t *testing.T) {
assert := func(size, exp uintptr, name string) {
t.Helper()
if size != exp {
t.Errorf("expected size of %s proto to be %d bytes, found %d bytes", name, exp, size)
}
}
if64Bit := func(yes, no uintptr) uintptr {
if bits.UintSize == 64 {
return yes
}
return no
}
var e Entry
assert(unsafe.Sizeof(e), if64Bit(48, 32), "Entry")
var sm SnapshotMetadata
assert(unsafe.Sizeof(sm), if64Bit(120, 68), "SnapshotMetadata")
var s Snapshot
assert(unsafe.Sizeof(s), if64Bit(144, 80), "Snapshot")
var m Message
assert(unsafe.Sizeof(m), if64Bit(264, 168), "Message")
var hs HardState
assert(unsafe.Sizeof(hs), 24, "HardState")
var cs ConfState
assert(unsafe.Sizeof(cs), if64Bit(104, 52), "ConfState")
var cc ConfChange
assert(unsafe.Sizeof(cc), if64Bit(48, 32), "ConfChange")
var ccs ConfChangeSingle
assert(unsafe.Sizeof(ccs), if64Bit(16, 12), "ConfChangeSingle")
var ccv2 ConfChangeV2
assert(unsafe.Sizeof(ccv2), if64Bit(56, 28), "ConfChangeV2")
}

View File

@ -103,7 +103,7 @@ stabilize 1 2
propose-conf-change 1
v3 v4 v5
----
INFO 1 ignoring conf change {ConfChangeTransitionAuto [{ConfChangeAddNode 3 {} [] 0} {ConfChangeAddNode 4 {} [] 0} {ConfChangeAddNode 5 {} [] 0}] [] {} [] 0} at config voters=(1 2)&&(1): must transition out of joint config first
INFO 1 ignoring conf change {ConfChangeTransitionAuto [{ConfChangeAddNode 3} {ConfChangeAddNode 4} {ConfChangeAddNode 5}] []} at config voters=(1 2)&&(1): must transition out of joint config first
# Propose a transition out of the joint config. We'll see this at index 6 below.
propose-conf-change 1
@ -165,7 +165,7 @@ stabilize
# Check that trying to transition out again won't do anything.
propose-conf-change 1
----
INFO 1 ignoring conf change {ConfChangeTransitionAuto [] [] {} [] 0} at config voters=(1 2): not in joint state; refusing empty conf change
INFO 1 ignoring conf change {ConfChangeTransitionAuto [] []} at config voters=(1 2): not in joint state; refusing empty conf change
# Finishes work for the empty entry we just proposed.
stabilize