Documentation ¶
Index ¶
- Variables
- type Action
- type ChangePeerType
- type CheckPolicy
- type Cluster
- func (*Cluster) Descriptor() ([]byte, []int)
- func (m *Cluster) GetID() uint64
- func (m *Cluster) GetMaxPeerCount() uint32
- func (m *Cluster) Marshal() (dAtA []byte, err error)
- func (m *Cluster) MarshalTo(dAtA []byte) (int, error)
- func (m *Cluster) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Cluster) ProtoMessage()
- func (m *Cluster) Reset()
- func (m *Cluster) Size() (n int)
- func (m *Cluster) String() string
- func (m *Cluster) Unmarshal(dAtA []byte) error
- func (m *Cluster) XXX_DiscardUnknown()
- func (m *Cluster) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Cluster) XXX_Merge(src proto.Message)
- func (m *Cluster) XXX_Size() int
- func (m *Cluster) XXX_Unmarshal(b []byte) error
- type ContainerState
- type Member
- func (*Member) Descriptor() ([]byte, []int)
- func (m *Member) GetAddr() string
- func (m *Member) GetID() uint64
- func (m *Member) GetName() string
- func (m *Member) Marshal() (dAtA []byte, err error)
- func (m *Member) MarshalTo(dAtA []byte) (int, error)
- func (m *Member) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Member) ProtoMessage()
- func (m *Member) Reset()
- func (m *Member) Size() (n int)
- func (m *Member) String() string
- func (m *Member) Unmarshal(dAtA []byte) error
- func (m *Member) XXX_DiscardUnknown()
- func (m *Member) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Member) XXX_Merge(src proto.Message)
- func (m *Member) XXX_Size() int
- func (m *Member) XXX_Unmarshal(b []byte) error
- type OperatorStatus
- type Pair
- func (*Pair) Descriptor() ([]byte, []int)
- func (m *Pair) GetKey() string
- func (m *Pair) GetValue() string
- func (m *Pair) Marshal() (dAtA []byte, err error)
- func (m *Pair) MarshalTo(dAtA []byte) (int, error)
- func (m *Pair) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Pair) ProtoMessage()
- func (m *Pair) Reset()
- func (m *Pair) Size() (n int)
- func (m *Pair) String() string
- func (m *Pair) Unmarshal(dAtA []byte) error
- func (m *Pair) XXX_DiscardUnknown()
- func (m *Pair) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Pair) XXX_Merge(src proto.Message)
- func (m *Pair) XXX_Size() int
- func (m *Pair) XXX_Unmarshal(b []byte) error
- type Peer
- func (*Peer) Descriptor() ([]byte, []int)
- func (m *Peer) GetContainerID() uint64
- func (m *Peer) GetID() uint64
- func (m *Peer) GetRole() PeerRole
- func (m *Peer) Marshal() (dAtA []byte, err error)
- func (m *Peer) MarshalTo(dAtA []byte) (int, error)
- func (m *Peer) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Peer) ProtoMessage()
- func (m *Peer) Reset()
- func (m *Peer) Size() (n int)
- func (m *Peer) String() string
- func (m *Peer) Unmarshal(dAtA []byte) error
- func (m *Peer) XXX_DiscardUnknown()
- func (m *Peer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Peer) XXX_Merge(src proto.Message)
- func (m *Peer) XXX_Size() int
- func (m *Peer) XXX_Unmarshal(b []byte) error
- type PeerRole
- type PeerStats
- func (*PeerStats) Descriptor() ([]byte, []int)
- func (m *PeerStats) GetDownSeconds() uint64
- func (m *PeerStats) GetPeer() Peer
- func (m *PeerStats) Marshal() (dAtA []byte, err error)
- func (m *PeerStats) MarshalTo(dAtA []byte) (int, error)
- func (m *PeerStats) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*PeerStats) ProtoMessage()
- func (m *PeerStats) Reset()
- func (m *PeerStats) Size() (n int)
- func (m *PeerStats) String() string
- func (m *PeerStats) Unmarshal(dAtA []byte) error
- func (m *PeerStats) XXX_DiscardUnknown()
- func (m *PeerStats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *PeerStats) XXX_Merge(src proto.Message)
- func (m *PeerStats) XXX_Size() int
- func (m *PeerStats) XXX_Unmarshal(b []byte) error
- type ResourceEpoch
- func (*ResourceEpoch) Descriptor() ([]byte, []int)
- func (m *ResourceEpoch) GetConfVer() uint64
- func (m *ResourceEpoch) GetVersion() uint64
- func (m *ResourceEpoch) Marshal() (dAtA []byte, err error)
- func (m *ResourceEpoch) MarshalTo(dAtA []byte) (int, error)
- func (m *ResourceEpoch) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ResourceEpoch) ProtoMessage()
- func (m *ResourceEpoch) Reset()
- func (m *ResourceEpoch) Size() (n int)
- func (m *ResourceEpoch) String() string
- func (m *ResourceEpoch) Unmarshal(dAtA []byte) error
- func (m *ResourceEpoch) XXX_DiscardUnknown()
- func (m *ResourceEpoch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ResourceEpoch) XXX_Merge(src proto.Message)
- func (m *ResourceEpoch) XXX_Size() int
- func (m *ResourceEpoch) XXX_Unmarshal(b []byte) error
- type ResourceKind
- type ResourceStat
- func (*ResourceStat) Descriptor() ([]byte, []int)
- func (m *ResourceStat) GetBytesRead() uint64
- func (m *ResourceStat) GetBytesWritten() uint64
- func (m *ResourceStat) GetKeysRead() uint64
- func (m *ResourceStat) GetKeysWritten() uint64
- func (m *ResourceStat) Marshal() (dAtA []byte, err error)
- func (m *ResourceStat) MarshalTo(dAtA []byte) (int, error)
- func (m *ResourceStat) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ResourceStat) ProtoMessage()
- func (m *ResourceStat) Reset()
- func (m *ResourceStat) Size() (n int)
- func (m *ResourceStat) String() string
- func (m *ResourceStat) Unmarshal(dAtA []byte) error
- func (m *ResourceStat) XXX_DiscardUnknown()
- func (m *ResourceStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ResourceStat) XXX_Merge(src proto.Message)
- func (m *ResourceStat) XXX_Size() int
- func (m *ResourceStat) XXX_Unmarshal(b []byte) error
- type Timestamp
- func (*Timestamp) Descriptor() ([]byte, []int)
- func (m *Timestamp) GetLogical() int64
- func (m *Timestamp) GetPhysical() int64
- func (m *Timestamp) Marshal() (dAtA []byte, err error)
- func (m *Timestamp) MarshalTo(dAtA []byte) (int, error)
- func (m *Timestamp) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Timestamp) ProtoMessage()
- func (m *Timestamp) Reset()
- func (m *Timestamp) Size() (n int)
- func (m *Timestamp) String() string
- func (m *Timestamp) Unmarshal(dAtA []byte) error
- func (m *Timestamp) XXX_DiscardUnknown()
- func (m *Timestamp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Timestamp) XXX_Merge(src proto.Message)
- func (m *Timestamp) XXX_Size() int
- func (m *Timestamp) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthMetapb = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowMetapb = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupMetapb = fmt.Errorf("proto: unexpected end of group") )
View Source
var Action_name = map[int32]string{
0: "None",
1: "ScaleOut",
}
View Source
var Action_value = map[string]int32{
"None": 0,
"ScaleOut": 1,
}
View Source
var ChangePeerType_name = map[int32]string{
0: "AddNode",
1: "RemoveNode",
2: "AddLearnerNode",
3: "ScalePeer",
}
View Source
var ChangePeerType_value = map[string]int32{
"AddNode": 0,
"RemoveNode": 1,
"AddLearnerNode": 2,
"ScalePeer": 3,
}
View Source
var CheckPolicy_name = map[int32]string{
0: "SCAN",
1: "APPROXIMATE",
2: "USEKEY",
}
View Source
var CheckPolicy_value = map[string]int32{
"SCAN": 0,
"APPROXIMATE": 1,
"USEKEY": 2,
}
View Source
var ContainerState_name = map[int32]string{
0: "UP",
1: "Offline",
2: "Tombstone",
}
View Source
var ContainerState_value = map[string]int32{
"UP": 0,
"Offline": 1,
"Tombstone": 2,
}
View Source
var OperatorStatus_name = map[int32]string{
0: "SUCCESS",
1: "TIMEOUT",
2: "CANCEL",
3: "REPLACE",
4: "RUNNING",
}
View Source
var OperatorStatus_value = map[string]int32{
"SUCCESS": 0,
"TIMEOUT": 1,
"CANCEL": 2,
"REPLACE": 3,
"RUNNING": 4,
}
View Source
var PeerRole_name = map[int32]string{
0: "Voter",
1: "Learner",
2: "IncomingVoter",
3: "DemotingVoter",
}
View Source
var PeerRole_value = map[string]int32{
"Voter": 0,
"Learner": 1,
"IncomingVoter": 2,
"DemotingVoter": 3,
}
View Source
var ResourceKind_name = map[int32]string{
0: "LeaderKind",
1: "ReplicaKind",
}
View Source
var ResourceKind_value = map[string]int32{
"LeaderKind": 0,
"ReplicaKind": 1,
}
Functions ¶
This section is empty.
Types ¶
type Action ¶
type Action int32
Action the action while a new node join the cluster
func (Action) EnumDescriptor ¶
type ChangePeerType ¶
type ChangePeerType int32
ChangePeerType change peer type
const ( ChangePeerType_AddNode ChangePeerType = 0 ChangePeerType_RemoveNode ChangePeerType = 1 ChangePeerType_AddLearnerNode ChangePeerType = 2 ChangePeerType_ScalePeer ChangePeerType = 3 )
func (ChangePeerType) EnumDescriptor ¶
func (ChangePeerType) EnumDescriptor() ([]byte, []int)
func (ChangePeerType) String ¶
func (x ChangePeerType) String() string
type CheckPolicy ¶
type CheckPolicy int32
CheckPolicy check policy
const ( CheckPolicy_SCAN CheckPolicy = 0 CheckPolicy_APPROXIMATE CheckPolicy = 1 CheckPolicy_USEKEY CheckPolicy = 2 )
func (CheckPolicy) EnumDescriptor ¶
func (CheckPolicy) EnumDescriptor() ([]byte, []int)
func (CheckPolicy) String ¶
func (x CheckPolicy) String() string
type Cluster ¶
type Cluster struct { ID uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` MaxPeerCount uint32 `protobuf:"varint,2,opt,name=maxPeerCount,proto3" json:"maxPeerCount,omitempty"` }
Cluster prophet cluster
func (*Cluster) Descriptor ¶
func (*Cluster) GetMaxPeerCount ¶
func (*Cluster) MarshalToSizedBuffer ¶
func (*Cluster) ProtoMessage ¶
func (*Cluster) ProtoMessage()
func (*Cluster) XXX_DiscardUnknown ¶
func (m *Cluster) XXX_DiscardUnknown()
func (*Cluster) XXX_Marshal ¶
func (*Cluster) XXX_Unmarshal ¶
type ContainerState ¶
type ContainerState int32
State the container state
const ( // UP is normal state ContainerState_UP ContainerState = 0 // Offline is the unavailable state ContainerState_Offline ContainerState = 1 // Tombstone is the destory state ContainerState_Tombstone ContainerState = 2 )
func (ContainerState) EnumDescriptor ¶
func (ContainerState) EnumDescriptor() ([]byte, []int)
func (ContainerState) String ¶
func (x ContainerState) String() string
type Member ¶
type Member struct { ID uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Addr string `protobuf:"bytes,3,opt,name=addr,proto3" json:"addr,omitempty"` }
Member prophet member
func (*Member) Descriptor ¶
func (*Member) MarshalToSizedBuffer ¶
func (*Member) ProtoMessage ¶
func (*Member) ProtoMessage()
func (*Member) XXX_DiscardUnknown ¶
func (m *Member) XXX_DiscardUnknown()
func (*Member) XXX_Marshal ¶
func (*Member) XXX_Unmarshal ¶
type OperatorStatus ¶
type OperatorStatus int32
OperatorStatus Operator Status
const ( OperatorStatus_SUCCESS OperatorStatus = 0 OperatorStatus_TIMEOUT OperatorStatus = 1 OperatorStatus_CANCEL OperatorStatus = 2 OperatorStatus_REPLACE OperatorStatus = 3 OperatorStatus_RUNNING OperatorStatus = 4 )
func (OperatorStatus) EnumDescriptor ¶
func (OperatorStatus) EnumDescriptor() ([]byte, []int)
func (OperatorStatus) String ¶
func (x OperatorStatus) String() string
type Pair ¶
type Pair struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` }
Pair key value pair
func (*Pair) Descriptor ¶
func (*Pair) ProtoMessage ¶
func (*Pair) ProtoMessage()
func (*Pair) XXX_DiscardUnknown ¶
func (m *Pair) XXX_DiscardUnknown()
func (*Pair) XXX_Unmarshal ¶
type Peer ¶
type Peer struct { ID uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` ContainerID uint64 `protobuf:"varint,2,opt,name=containerID,proto3" json:"containerID,omitempty"` Role PeerRole `protobuf:"varint,3,opt,name=role,proto3,enum=metapb.PeerRole" json:"role,omitempty"` }
Peer is a replica of the resource, we called peer
func (*Peer) Descriptor ¶
func (*Peer) GetContainerID ¶
func (*Peer) ProtoMessage ¶
func (*Peer) ProtoMessage()
func (*Peer) XXX_DiscardUnknown ¶
func (m *Peer) XXX_DiscardUnknown()
func (*Peer) XXX_Unmarshal ¶
type PeerStats ¶
type PeerStats struct { Peer Peer `protobuf:"bytes,1,opt,name=peer,proto3" json:"peer"` DownSeconds uint64 `protobuf:"varint,2,opt,name=downSeconds,proto3" json:"downSeconds,omitempty"` }
PeerStats peer stats
func (*PeerStats) Descriptor ¶
func (*PeerStats) GetDownSeconds ¶
func (*PeerStats) MarshalToSizedBuffer ¶
func (*PeerStats) ProtoMessage ¶
func (*PeerStats) ProtoMessage()
func (*PeerStats) XXX_DiscardUnknown ¶
func (m *PeerStats) XXX_DiscardUnknown()
func (*PeerStats) XXX_Marshal ¶
func (*PeerStats) XXX_Unmarshal ¶
type ResourceEpoch ¶
type ResourceEpoch struct { // Conf change version, auto increment when add or remove peer ConfVer uint64 `protobuf:"varint,1,opt,name=confVer,proto3" json:"confVer,omitempty"` // Resource version, auto increment when split or merge Version uint64 `protobuf:"varint,2,opt,name=version,proto3" json:"version,omitempty"` }
ResourceEpoch resource epoch
func (*ResourceEpoch) Descriptor ¶
func (*ResourceEpoch) Descriptor() ([]byte, []int)
func (*ResourceEpoch) GetConfVer ¶
func (m *ResourceEpoch) GetConfVer() uint64
func (*ResourceEpoch) GetVersion ¶
func (m *ResourceEpoch) GetVersion() uint64
func (*ResourceEpoch) Marshal ¶
func (m *ResourceEpoch) Marshal() (dAtA []byte, err error)
func (*ResourceEpoch) MarshalToSizedBuffer ¶
func (m *ResourceEpoch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ResourceEpoch) ProtoMessage ¶
func (*ResourceEpoch) ProtoMessage()
func (*ResourceEpoch) Reset ¶
func (m *ResourceEpoch) Reset()
func (*ResourceEpoch) Size ¶
func (m *ResourceEpoch) Size() (n int)
func (*ResourceEpoch) String ¶
func (m *ResourceEpoch) String() string
func (*ResourceEpoch) Unmarshal ¶
func (m *ResourceEpoch) Unmarshal(dAtA []byte) error
func (*ResourceEpoch) XXX_DiscardUnknown ¶
func (m *ResourceEpoch) XXX_DiscardUnknown()
func (*ResourceEpoch) XXX_Marshal ¶
func (m *ResourceEpoch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ResourceEpoch) XXX_Merge ¶
func (m *ResourceEpoch) XXX_Merge(src proto.Message)
func (*ResourceEpoch) XXX_Size ¶
func (m *ResourceEpoch) XXX_Size() int
func (*ResourceEpoch) XXX_Unmarshal ¶
func (m *ResourceEpoch) XXX_Unmarshal(b []byte) error
type ResourceKind ¶
type ResourceKind int32
ResourceKind the resource king
const ( ResourceKind_LeaderKind ResourceKind = 0 ResourceKind_ReplicaKind ResourceKind = 1 )
func (ResourceKind) EnumDescriptor ¶
func (ResourceKind) EnumDescriptor() ([]byte, []int)
func (ResourceKind) String ¶
func (x ResourceKind) String() string
type ResourceStat ¶
type ResourceStat struct { // Bytes written for the container during this period. BytesWritten uint64 `protobuf:"varint,1,opt,name=bytesWritten,proto3" json:"bytesWritten,omitempty"` // Bytes read for the container during this period. BytesRead uint64 `protobuf:"varint,2,opt,name=bytesRead,proto3" json:"bytesRead,omitempty"` // Bytes written for the container during this period. KeysWritten uint64 `protobuf:"varint,3,opt,name=keysWritten,proto3" json:"keysWritten,omitempty"` // Bytes read for the container during this period. KeysRead uint64 `protobuf:"varint,4,opt,name=keysRead,proto3" json:"keysRead,omitempty"` }
ResourceStat resource stat
func (*ResourceStat) Descriptor ¶
func (*ResourceStat) Descriptor() ([]byte, []int)
func (*ResourceStat) GetBytesRead ¶
func (m *ResourceStat) GetBytesRead() uint64
func (*ResourceStat) GetBytesWritten ¶
func (m *ResourceStat) GetBytesWritten() uint64
func (*ResourceStat) GetKeysRead ¶
func (m *ResourceStat) GetKeysRead() uint64
func (*ResourceStat) GetKeysWritten ¶
func (m *ResourceStat) GetKeysWritten() uint64
func (*ResourceStat) Marshal ¶
func (m *ResourceStat) Marshal() (dAtA []byte, err error)
func (*ResourceStat) MarshalToSizedBuffer ¶
func (m *ResourceStat) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ResourceStat) ProtoMessage ¶
func (*ResourceStat) ProtoMessage()
func (*ResourceStat) Reset ¶
func (m *ResourceStat) Reset()
func (*ResourceStat) Size ¶
func (m *ResourceStat) Size() (n int)
func (*ResourceStat) String ¶
func (m *ResourceStat) String() string
func (*ResourceStat) Unmarshal ¶
func (m *ResourceStat) Unmarshal(dAtA []byte) error
func (*ResourceStat) XXX_DiscardUnknown ¶
func (m *ResourceStat) XXX_DiscardUnknown()
func (*ResourceStat) XXX_Marshal ¶
func (m *ResourceStat) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ResourceStat) XXX_Merge ¶
func (m *ResourceStat) XXX_Merge(src proto.Message)
func (*ResourceStat) XXX_Size ¶
func (m *ResourceStat) XXX_Size() int
func (*ResourceStat) XXX_Unmarshal ¶
func (m *ResourceStat) XXX_Unmarshal(b []byte) error
type Timestamp ¶
type Timestamp struct { Physical int64 `protobuf:"varint,1,opt,name=physical,proto3" json:"physical,omitempty"` Logical int64 `protobuf:"varint,2,opt,name=logical,proto3" json:"logical,omitempty"` }
Timestamp tso timestamp
func (*Timestamp) Descriptor ¶
func (*Timestamp) GetLogical ¶
func (*Timestamp) GetPhysical ¶
func (*Timestamp) MarshalToSizedBuffer ¶
func (*Timestamp) ProtoMessage ¶
func (*Timestamp) ProtoMessage()
func (*Timestamp) XXX_DiscardUnknown ¶
func (m *Timestamp) XXX_DiscardUnknown()
func (*Timestamp) XXX_Marshal ¶
func (*Timestamp) XXX_Unmarshal ¶
Click to show internal directories.
Click to hide internal directories.