raft_proto

package
v0.0.0-...-e532b39 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 15, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthRaft = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowRaft   = fmt.Errorf("proto: integer overflow")
)
View Source
var EntryType_name = map[int32]string{
	0: "System",
	1: "Normal",
}
View Source
var EntryType_value = map[string]int32{
	"System": 0,
	"Normal": 1,
}
View Source
var MessageType_name = map[int32]string{
	0: "HeartBeatRequest",
	1: "HeartBeatResponse",
}
View Source
var MessageType_value = map[string]int32{
	"HeartBeatRequest":  0,
	"HeartBeatResponse": 1,
}

Functions

This section is empty.

Types

type AppendEntriesRequest

type AppendEntriesRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AppendEntriesRequest) Descriptor

func (*AppendEntriesRequest) Descriptor() ([]byte, []int)

func (*AppendEntriesRequest) Marshal

func (m *AppendEntriesRequest) Marshal() (dAtA []byte, err error)

func (*AppendEntriesRequest) MarshalTo

func (m *AppendEntriesRequest) MarshalTo(dAtA []byte) (int, error)

func (*AppendEntriesRequest) ProtoMessage

func (*AppendEntriesRequest) ProtoMessage()

func (*AppendEntriesRequest) Reset

func (m *AppendEntriesRequest) Reset()

func (*AppendEntriesRequest) Size

func (m *AppendEntriesRequest) Size() (n int)

func (*AppendEntriesRequest) String

func (m *AppendEntriesRequest) String() string

func (*AppendEntriesRequest) Unmarshal

func (m *AppendEntriesRequest) Unmarshal(dAtA []byte) error

func (*AppendEntriesRequest) XXX_DiscardUnknown

func (m *AppendEntriesRequest) XXX_DiscardUnknown()

func (*AppendEntriesRequest) XXX_Marshal

func (m *AppendEntriesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AppendEntriesRequest) XXX_Merge

func (m *AppendEntriesRequest) XXX_Merge(src proto.Message)

func (*AppendEntriesRequest) XXX_Size

func (m *AppendEntriesRequest) XXX_Size() int

func (*AppendEntriesRequest) XXX_Unmarshal

func (m *AppendEntriesRequest) XXX_Unmarshal(b []byte) error

type AppendEntriesResponse

type AppendEntriesResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*AppendEntriesResponse) Descriptor

func (*AppendEntriesResponse) Descriptor() ([]byte, []int)

func (*AppendEntriesResponse) Marshal

func (m *AppendEntriesResponse) Marshal() (dAtA []byte, err error)

func (*AppendEntriesResponse) MarshalTo

func (m *AppendEntriesResponse) MarshalTo(dAtA []byte) (int, error)

func (*AppendEntriesResponse) ProtoMessage

func (*AppendEntriesResponse) ProtoMessage()

func (*AppendEntriesResponse) Reset

func (m *AppendEntriesResponse) Reset()

func (*AppendEntriesResponse) Size

func (m *AppendEntriesResponse) Size() (n int)

func (*AppendEntriesResponse) String

func (m *AppendEntriesResponse) String() string

func (*AppendEntriesResponse) Unmarshal

func (m *AppendEntriesResponse) Unmarshal(dAtA []byte) error

func (*AppendEntriesResponse) XXX_DiscardUnknown

func (m *AppendEntriesResponse) XXX_DiscardUnknown()

func (*AppendEntriesResponse) XXX_Marshal

func (m *AppendEntriesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AppendEntriesResponse) XXX_Merge

func (m *AppendEntriesResponse) XXX_Merge(src proto.Message)

func (*AppendEntriesResponse) XXX_Size

func (m *AppendEntriesResponse) XXX_Size() int

func (*AppendEntriesResponse) XXX_Unmarshal

func (m *AppendEntriesResponse) XXX_Unmarshal(b []byte) error

type CompactLogRequest

type CompactLogRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*CompactLogRequest) Descriptor

func (*CompactLogRequest) Descriptor() ([]byte, []int)

func (*CompactLogRequest) Marshal

func (m *CompactLogRequest) Marshal() (dAtA []byte, err error)

func (*CompactLogRequest) MarshalTo

func (m *CompactLogRequest) MarshalTo(dAtA []byte) (int, error)

func (*CompactLogRequest) ProtoMessage

func (*CompactLogRequest) ProtoMessage()

func (*CompactLogRequest) Reset

func (m *CompactLogRequest) Reset()

func (*CompactLogRequest) Size

func (m *CompactLogRequest) Size() (n int)

func (*CompactLogRequest) String

func (m *CompactLogRequest) String() string

func (*CompactLogRequest) Unmarshal

func (m *CompactLogRequest) Unmarshal(dAtA []byte) error

func (*CompactLogRequest) XXX_DiscardUnknown

func (m *CompactLogRequest) XXX_DiscardUnknown()

func (*CompactLogRequest) XXX_Marshal

func (m *CompactLogRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*CompactLogRequest) XXX_Merge

func (m *CompactLogRequest) XXX_Merge(src proto.Message)

func (*CompactLogRequest) XXX_Size

func (m *CompactLogRequest) XXX_Size() int

func (*CompactLogRequest) XXX_Unmarshal

func (m *CompactLogRequest) XXX_Unmarshal(b []byte) error

type Entry

type Entry struct {
	Type                 EntryType `protobuf:"varint,1,opt,name=Type,proto3,enum=raft.proto.EntryType" json:"Type,omitempty"`
	Term                 int64     `protobuf:"varint,3,opt,name=Term,proto3" json:"Term,omitempty"`
	Index                int64     `protobuf:"varint,4,opt,name=Index,proto3" json:"Index,omitempty"`
	Data                 []byte    `protobuf:"bytes,5,opt,name=Data,proto3" json:"Data,omitempty"`
	Digest               []byte    `protobuf:"bytes,6,opt,name=Digest,proto3" json:"Digest,omitempty"`
	XXX_NoUnkeyedLiteral struct{}  `json:"-"`
	XXX_unrecognized     []byte    `json:"-"`
	XXX_sizecache        int32     `json:"-"`
}

func (*Entry) Descriptor

func (*Entry) Descriptor() ([]byte, []int)

func (*Entry) Marshal

func (m *Entry) Marshal() (dAtA []byte, err error)

func (*Entry) MarshalTo

func (m *Entry) MarshalTo(dAtA []byte) (int, error)

func (*Entry) ProtoMessage

func (*Entry) ProtoMessage()

func (*Entry) Reset

func (m *Entry) Reset()

func (*Entry) Size

func (m *Entry) Size() (n int)

func (*Entry) String

func (m *Entry) String() string

func (*Entry) Unmarshal

func (m *Entry) Unmarshal(dAtA []byte) error

func (*Entry) XXX_DiscardUnknown

func (m *Entry) XXX_DiscardUnknown()

func (*Entry) XXX_Marshal

func (m *Entry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Entry) XXX_Merge

func (m *Entry) XXX_Merge(src proto.Message)

func (*Entry) XXX_Size

func (m *Entry) XXX_Size() int

func (*Entry) XXX_Unmarshal

func (m *Entry) XXX_Unmarshal(b []byte) error

type EntryType

type EntryType int32
const (
	System EntryType = 0
	Normal EntryType = 1
)

func (EntryType) EnumDescriptor

func (EntryType) EnumDescriptor() ([]byte, []int)

func (EntryType) String

func (x EntryType) String() string

type InstallSnapshotRequest

type InstallSnapshotRequest struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InstallSnapshotRequest) Descriptor

func (*InstallSnapshotRequest) Descriptor() ([]byte, []int)

func (*InstallSnapshotRequest) Marshal

func (m *InstallSnapshotRequest) Marshal() (dAtA []byte, err error)

func (*InstallSnapshotRequest) MarshalTo

func (m *InstallSnapshotRequest) MarshalTo(dAtA []byte) (int, error)

func (*InstallSnapshotRequest) ProtoMessage

func (*InstallSnapshotRequest) ProtoMessage()

func (*InstallSnapshotRequest) Reset

func (m *InstallSnapshotRequest) Reset()

func (*InstallSnapshotRequest) Size

func (m *InstallSnapshotRequest) Size() (n int)

func (*InstallSnapshotRequest) String

func (m *InstallSnapshotRequest) String() string

func (*InstallSnapshotRequest) Unmarshal

func (m *InstallSnapshotRequest) Unmarshal(dAtA []byte) error

func (*InstallSnapshotRequest) XXX_DiscardUnknown

func (m *InstallSnapshotRequest) XXX_DiscardUnknown()

func (*InstallSnapshotRequest) XXX_Marshal

func (m *InstallSnapshotRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstallSnapshotRequest) XXX_Merge

func (m *InstallSnapshotRequest) XXX_Merge(src proto.Message)

func (*InstallSnapshotRequest) XXX_Size

func (m *InstallSnapshotRequest) XXX_Size() int

func (*InstallSnapshotRequest) XXX_Unmarshal

func (m *InstallSnapshotRequest) XXX_Unmarshal(b []byte) error

type InstallSnapshotResponse

type InstallSnapshotResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InstallSnapshotResponse) Descriptor

func (*InstallSnapshotResponse) Descriptor() ([]byte, []int)

func (*InstallSnapshotResponse) Marshal

func (m *InstallSnapshotResponse) Marshal() (dAtA []byte, err error)

func (*InstallSnapshotResponse) MarshalTo

func (m *InstallSnapshotResponse) MarshalTo(dAtA []byte) (int, error)

func (*InstallSnapshotResponse) ProtoMessage

func (*InstallSnapshotResponse) ProtoMessage()

func (*InstallSnapshotResponse) Reset

func (m *InstallSnapshotResponse) Reset()

func (*InstallSnapshotResponse) Size

func (m *InstallSnapshotResponse) Size() (n int)

func (*InstallSnapshotResponse) String

func (m *InstallSnapshotResponse) String() string

func (*InstallSnapshotResponse) Unmarshal

func (m *InstallSnapshotResponse) Unmarshal(dAtA []byte) error

func (*InstallSnapshotResponse) XXX_DiscardUnknown

func (m *InstallSnapshotResponse) XXX_DiscardUnknown()

func (*InstallSnapshotResponse) XXX_Marshal

func (m *InstallSnapshotResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstallSnapshotResponse) XXX_Merge

func (m *InstallSnapshotResponse) XXX_Merge(src proto.Message)

func (*InstallSnapshotResponse) XXX_Size

func (m *InstallSnapshotResponse) XXX_Size() int

func (*InstallSnapshotResponse) XXX_Unmarshal

func (m *InstallSnapshotResponse) XXX_Unmarshal(b []byte) error

type MessageType

type MessageType int32
const (
	HeartBeatRequest  MessageType = 0
	HeartBeatResponse MessageType = 1
)

func (MessageType) EnumDescriptor

func (MessageType) EnumDescriptor() ([]byte, []int)

func (MessageType) String

func (x MessageType) String() string

type RequestVoteRequest

type RequestVoteRequest struct {
	CandidateId          string   `protobuf:"bytes,1,opt,name=CandidateId,proto3" json:"CandidateId,omitempty"`
	Term                 int64    `protobuf:"varint,2,opt,name=Term,proto3" json:"Term,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RequestVoteRequest) Descriptor

func (*RequestVoteRequest) Descriptor() ([]byte, []int)

func (*RequestVoteRequest) Marshal

func (m *RequestVoteRequest) Marshal() (dAtA []byte, err error)

func (*RequestVoteRequest) MarshalTo

func (m *RequestVoteRequest) MarshalTo(dAtA []byte) (int, error)

func (*RequestVoteRequest) ProtoMessage

func (*RequestVoteRequest) ProtoMessage()

func (*RequestVoteRequest) Reset

func (m *RequestVoteRequest) Reset()

func (*RequestVoteRequest) Size

func (m *RequestVoteRequest) Size() (n int)

func (*RequestVoteRequest) String

func (m *RequestVoteRequest) String() string

func (*RequestVoteRequest) Unmarshal

func (m *RequestVoteRequest) Unmarshal(dAtA []byte) error

func (*RequestVoteRequest) XXX_DiscardUnknown

func (m *RequestVoteRequest) XXX_DiscardUnknown()

func (*RequestVoteRequest) XXX_Marshal

func (m *RequestVoteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RequestVoteRequest) XXX_Merge

func (m *RequestVoteRequest) XXX_Merge(src proto.Message)

func (*RequestVoteRequest) XXX_Size

func (m *RequestVoteRequest) XXX_Size() int

func (*RequestVoteRequest) XXX_Unmarshal

func (m *RequestVoteRequest) XXX_Unmarshal(b []byte) error

type RequestVoteResponse

type RequestVoteResponse struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*RequestVoteResponse) Descriptor

func (*RequestVoteResponse) Descriptor() ([]byte, []int)

func (*RequestVoteResponse) Marshal

func (m *RequestVoteResponse) Marshal() (dAtA []byte, err error)

func (*RequestVoteResponse) MarshalTo

func (m *RequestVoteResponse) MarshalTo(dAtA []byte) (int, error)

func (*RequestVoteResponse) ProtoMessage

func (*RequestVoteResponse) ProtoMessage()

func (*RequestVoteResponse) Reset

func (m *RequestVoteResponse) Reset()

func (*RequestVoteResponse) Size

func (m *RequestVoteResponse) Size() (n int)

func (*RequestVoteResponse) String

func (m *RequestVoteResponse) String() string

func (*RequestVoteResponse) Unmarshal

func (m *RequestVoteResponse) Unmarshal(dAtA []byte) error

func (*RequestVoteResponse) XXX_DiscardUnknown

func (m *RequestVoteResponse) XXX_DiscardUnknown()

func (*RequestVoteResponse) XXX_Marshal

func (m *RequestVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RequestVoteResponse) XXX_Merge

func (m *RequestVoteResponse) XXX_Merge(src proto.Message)

func (*RequestVoteResponse) XXX_Size

func (m *RequestVoteResponse) XXX_Size() int

func (*RequestVoteResponse) XXX_Unmarshal

func (m *RequestVoteResponse) XXX_Unmarshal(b []byte) error

type RpcMessage

type RpcMessage struct {
	Type                 MessageType `protobuf:"varint,1,opt,name=Type,proto3,enum=raft.proto.MessageType" json:"Type,omitempty"`
	Term                 int64       `protobuf:"varint,2,opt,name=Term,proto3" json:"Term,omitempty"`
	XXX_NoUnkeyedLiteral struct{}    `json:"-"`
	XXX_unrecognized     []byte      `json:"-"`
	XXX_sizecache        int32       `json:"-"`
}

func (*RpcMessage) Descriptor

func (*RpcMessage) Descriptor() ([]byte, []int)

func (*RpcMessage) Marshal

func (m *RpcMessage) Marshal() (dAtA []byte, err error)

func (*RpcMessage) MarshalTo

func (m *RpcMessage) MarshalTo(dAtA []byte) (int, error)

func (*RpcMessage) ProtoMessage

func (*RpcMessage) ProtoMessage()

func (*RpcMessage) Reset

func (m *RpcMessage) Reset()

func (*RpcMessage) Size

func (m *RpcMessage) Size() (n int)

func (*RpcMessage) String

func (m *RpcMessage) String() string

func (*RpcMessage) Unmarshal

func (m *RpcMessage) Unmarshal(dAtA []byte) error

func (*RpcMessage) XXX_DiscardUnknown

func (m *RpcMessage) XXX_DiscardUnknown()

func (*RpcMessage) XXX_Marshal

func (m *RpcMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RpcMessage) XXX_Merge

func (m *RpcMessage) XXX_Merge(src proto.Message)

func (*RpcMessage) XXX_Size

func (m *RpcMessage) XXX_Size() int

func (*RpcMessage) XXX_Unmarshal

func (m *RpcMessage) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL