Documentation ¶
Index ¶
- Variables
- type CMD
- type CMDType
- type ClusterConfig
- func (*ClusterConfig) Descriptor() ([]byte, []int)deprecated
- func (x *ClusterConfig) GetClusterID() int32
- func (x *ClusterConfig) GetExportWill() []byte
- func (x *ClusterConfig) GetExportedList() *ExportedList
- func (x *ClusterConfig) GetExporting() []byte
- func (x *ClusterConfig) GetImportClusterID() int32
- func (x *ClusterConfig) GetImportWill() []byte
- func (x *ClusterConfig) GetLeaderID() int32
- func (x *ClusterConfig) GetNodes() []*Node
- func (x *ClusterConfig) GetReplica() int32
- func (x *ClusterConfig) GetSlotCount() int32
- func (x *ClusterConfig) GetSlots() []byte
- func (x *ClusterConfig) GetState() ClusterState
- func (x *ClusterConfig) GetVersion() int32
- func (x *ClusterConfig) GetWeight() int32
- func (*ClusterConfig) ProtoMessage()
- func (x *ClusterConfig) ProtoReflect() protoreflect.Message
- func (x *ClusterConfig) Reset()
- func (x *ClusterConfig) String() string
- type ClusterConfigChange
- func (*ClusterConfigChange) Descriptor() ([]byte, []int)deprecated
- func (x *ClusterConfigChange) GetClusterID() int32
- func (x *ClusterConfigChange) GetVersion() int32
- func (*ClusterConfigChange) ProtoMessage()
- func (x *ClusterConfigChange) ProtoReflect() protoreflect.Message
- func (x *ClusterConfigChange) Reset()
- func (x *ClusterConfigChange) String() string
- type ClusterConfigListResp
- func (*ClusterConfigListResp) Descriptor() ([]byte, []int)deprecated
- func (x *ClusterConfigListResp) GetClusterConfigs() []*ClusterConfig
- func (*ClusterConfigListResp) ProtoMessage()
- func (x *ClusterConfigListResp) ProtoReflect() protoreflect.Message
- func (x *ClusterConfigListResp) Reset()
- func (x *ClusterConfigListResp) String() string
- type ClusterConfigReq
- type ClusterConfigResp
- type ClusterState
- func (ClusterState) Descriptor() protoreflect.EnumDescriptor
- func (x ClusterState) Enum() *ClusterState
- func (ClusterState) EnumDescriptor() ([]byte, []int)deprecated
- func (x ClusterState) Number() protoreflect.EnumNumber
- func (x ClusterState) String() string
- func (ClusterState) Type() protoreflect.EnumType
- type ConnectInfo
- func (*ConnectInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ConnectInfo) GetClusterID() int32
- func (x *ConnectInfo) GetNodeID() int32
- func (*ConnectInfo) ProtoMessage()
- func (x *ConnectInfo) ProtoReflect() protoreflect.Message
- func (x *ConnectInfo) Reset()
- func (x *ConnectInfo) String() string
- type ConnectReq
- type ConnectResp
- func (*ConnectResp) Descriptor() ([]byte, []int)deprecated
- func (x *ConnectResp) GetProxyConfig() *ProxyConfig
- func (x *ConnectResp) GetReason() string
- func (x *ConnectResp) GetStatus() Status
- func (*ConnectResp) ProtoMessage()
- func (x *ConnectResp) ProtoReflect() protoreflect.Message
- func (x *ConnectResp) Reset()
- func (x *ConnectResp) String() string
- type Encoder
- func (e *Encoder) Bytes() []byte
- func (e *Encoder) Len() int
- func (e *Encoder) WriteBinary(b []byte)
- func (e *Encoder) WriteByte(b byte) error
- func (e *Encoder) WriteBytes(b []byte)
- func (e *Encoder) WriteInt(i int) error
- func (e *Encoder) WriteInt16(i int)
- func (e *Encoder) WriteInt32(i int32)
- func (e *Encoder) WriteInt64(i int64)
- func (e *Encoder) WriteString(str string)
- func (e *Encoder) WriteStringAll(str string)
- func (e *Encoder) WriteUint16(i uint16)
- func (e *Encoder) WriteUint32(i uint32)
- func (e *Encoder) WriteUint64(i uint64)
- func (e *Encoder) WriteUint8(i uint8)
- func (e *Encoder) WriteVariable(v int)
- type Exported
- func (*Exported) Descriptor() ([]byte, []int)deprecated
- func (x *Exported) GetNo() string
- func (x *Exported) GetPath() string
- func (x *Exported) GetSlots() []byte
- func (*Exported) ProtoMessage()
- func (x *Exported) ProtoReflect() protoreflect.Message
- func (x *Exported) Reset()
- func (x *Exported) String() string
- type ExportedList
- type Exporting
- type Imported
- type Node
- func (*Node) Descriptor() ([]byte, []int)deprecated
- func (x *Node) GetJoin() bool
- func (x *Node) GetNodeAPIAddr() string
- func (x *Node) GetNodeID() int32
- func (x *Node) GetNodeRPCAddr() string
- func (x *Node) GetNodeRaftAddr() string
- func (x *Node) GetRole() Role
- func (x *Node) GetTcpAddr() string
- func (x *Node) GetWsAddr() string
- func (*Node) ProtoMessage()
- func (x *Node) ProtoReflect() protoreflect.Message
- func (x *Node) Reset()
- func (x *Node) String() string
- type Ping
- func (*Ping) Descriptor() ([]byte, []int)deprecated
- func (x *Ping) GetClusterID() int32
- func (x *Ping) GetLeaderID() int32
- func (x *Ping) GetTotalVersion() int32
- func (x *Ping) GetVersion() int32
- func (*Ping) ProtoMessage()
- func (x *Ping) ProtoReflect() protoreflect.Message
- func (x *Ping) Reset()
- func (x *Ping) String() string
- type Protocol
- type ProxyConfig
- func (*ProxyConfig) Descriptor() ([]byte, []int)deprecated
- func (x *ProxyConfig) GetDowloadSlotBackupURL() string
- func (x *ProxyConfig) GetRemoveSlotBackupURL() string
- func (x *ProxyConfig) GetUploadSlotBackupURL() string
- func (*ProxyConfig) ProtoMessage()
- func (x *ProxyConfig) ProtoReflect() protoreflect.Message
- func (x *ProxyConfig) Reset()
- func (x *ProxyConfig) String() string
- type RegisterNodeResp
- func (*RegisterNodeResp) Descriptor() ([]byte, []int)deprecated
- func (x *RegisterNodeResp) GetClusterID() int32
- func (x *RegisterNodeResp) GetReason() string
- func (x *RegisterNodeResp) GetStatus() Status
- func (*RegisterNodeResp) ProtoMessage()
- func (x *RegisterNodeResp) ProtoReflect() protoreflect.Message
- func (x *RegisterNodeResp) Reset()
- func (x *RegisterNodeResp) String() string
- type Role
- type Status
- type StatusResp
Constants ¶
This section is empty.
Variables ¶
var ( Status_name = map[int32]string{ 0: "Error", 1: "Success", } Status_value = map[string]int32{ "Error": 0, "Success": 1, } )
Enum value maps for Status.
var ( Role_name = map[int32]string{ 0: "Unknown", 1: "Master", 2: "Slave", } Role_value = map[string]int32{ "Unknown": 0, "Master": 1, "Slave": 2, } )
Enum value maps for Role.
var ( ClusterState_name = map[int32]string{ 0: "WaitReady", 1: "Ready", 2: "Migration", } ClusterState_value = map[string]int32{ "WaitReady": 0, "Ready": 1, "Migration": 2, } )
Enum value maps for ClusterState.
var File_pkg_lmproxyproto_cmd_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type CMDType ¶
type CMDType uint8
CMDType cmd类型
const ( // CMDTypeNone 无 CMDTypeNone CMDType = iota // CMDTypeConnect 连接 CMDTypeConnect // CMDTypeConnectResp 连接回执 CMDTypeConnectResp // CMDTypeClusterConfigReq 配置请求 CMDTypeClusterConfigReq // CMDTypeClusterConfigResp 配置返回 CMDTypeClusterConfigResp // CMDTypeClusterConfigUpdate 配置更新 CMDTypeClusterConfigUpdate // CMDTypeUploadClusterConfig 代理服务命令节点上传分布式配置 CMDTypeUploadClusterConfig // CMDTypeClusterConfigUpload 节点上传配置 CMDTypeClusterConfigUpload // CMDTypeRegisterNode 注册节点 CMDTypeRegisterNode // CMDTypeRegisterNodeResp 注册节点返回 CMDTypeRegisterNodeResp // CMDTypePing 心跳 CMDTypePing // CMDTypePong 心跳响应 CMDTypePong // CMDTypeStatusResp CMDTypeStatusResp CMDTypeStatusResp // CMDTypeExporting CMDTypeExporting CMDTypeExporting // CMDTypeExported CMDTypeExported CMDTypeExported // CMDTypeExportedAll CMDTypeExportedAll CMDTypeExportedAll // CMDTypeImportFrom CMDTypeImportFrom CMDTypeImportFrom // CMDTypeImported CMDTypeImported CMDTypeImported // CMDTypeClusterConfigListReq 请求分布式配置列表 (n-p) CMDTypeClusterConfigListReq // CMDTypeClusterConfigListResp 分布式配置列表返回 (p-n) CMDTypeClusterConfigListResp // CMDTypeClusterConfigListChange 分布配置列表有变动 CMDTypeClusterConfigListChange )
type ClusterConfig ¶
type ClusterConfig struct { Version int32 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` // 配置版本 SlotCount int32 `protobuf:"varint,2,opt,name=slotCount,proto3" json:"slotCount,omitempty"` // slot 总数量 ClusterID int32 `protobuf:"varint,3,opt,name=clusterID,proto3" json:"clusterID,omitempty"` // cluster id Replica int32 `protobuf:"varint,4,opt,name=replica,proto3" json:"replica,omitempty"` // 副本数 State ClusterState `protobuf:"varint,5,opt,name=state,proto3,enum=ClusterState" json:"state,omitempty"` // 状态 Slots []byte `protobuf:"bytes,6,opt,name=slots,proto3" json:"slots,omitempty"` // slot bitmap Nodes []*Node `protobuf:"bytes,7,rep,name=nodes,proto3" json:"nodes,omitempty"` // 节点信息 LeaderID int32 `protobuf:"varint,8,opt,name=leaderID,proto3" json:"leaderID,omitempty"` // 领导节点的id ImportClusterID int32 `protobuf:"varint,9,opt,name=importClusterID,proto3" json:"importClusterID,omitempty"` // 要导入的分布式ID ImportWill []byte `protobuf:"bytes,10,opt,name=importWill,proto3" json:"importWill,omitempty"` // 将要引入的slots ExportWill []byte `protobuf:"bytes,11,opt,name=exportWill,proto3" json:"exportWill,omitempty"` // 将要导出的slots Exporting []byte `protobuf:"bytes,12,opt,name=exporting,proto3" json:"exporting,omitempty"` // 正在导出的slot(正在导出的slot将被锁定,不接受数据) ExportedList *ExportedList `protobuf:"bytes,13,opt,name=exportedList,proto3" json:"exportedList,omitempty"` // 已导出的slot Weight int32 `protobuf:"varint,14,opt,name=weight,proto3" json:"weight,omitempty"` // 权重 // contains filtered or unexported fields }
func (*ClusterConfig) Descriptor
deprecated
func (*ClusterConfig) Descriptor() ([]byte, []int)
Deprecated: Use ClusterConfig.ProtoReflect.Descriptor instead.
func (*ClusterConfig) GetClusterID ¶
func (x *ClusterConfig) GetClusterID() int32
func (*ClusterConfig) GetExportWill ¶
func (x *ClusterConfig) GetExportWill() []byte
func (*ClusterConfig) GetExportedList ¶
func (x *ClusterConfig) GetExportedList() *ExportedList
func (*ClusterConfig) GetExporting ¶
func (x *ClusterConfig) GetExporting() []byte
func (*ClusterConfig) GetImportClusterID ¶
func (x *ClusterConfig) GetImportClusterID() int32
func (*ClusterConfig) GetImportWill ¶
func (x *ClusterConfig) GetImportWill() []byte
func (*ClusterConfig) GetLeaderID ¶
func (x *ClusterConfig) GetLeaderID() int32
func (*ClusterConfig) GetNodes ¶
func (x *ClusterConfig) GetNodes() []*Node
func (*ClusterConfig) GetReplica ¶
func (x *ClusterConfig) GetReplica() int32
func (*ClusterConfig) GetSlotCount ¶
func (x *ClusterConfig) GetSlotCount() int32
func (*ClusterConfig) GetSlots ¶
func (x *ClusterConfig) GetSlots() []byte
func (*ClusterConfig) GetState ¶
func (x *ClusterConfig) GetState() ClusterState
func (*ClusterConfig) GetVersion ¶
func (x *ClusterConfig) GetVersion() int32
func (*ClusterConfig) GetWeight ¶
func (x *ClusterConfig) GetWeight() int32
func (*ClusterConfig) ProtoMessage ¶
func (*ClusterConfig) ProtoMessage()
func (*ClusterConfig) ProtoReflect ¶
func (x *ClusterConfig) ProtoReflect() protoreflect.Message
func (*ClusterConfig) Reset ¶
func (x *ClusterConfig) Reset()
func (*ClusterConfig) String ¶
func (x *ClusterConfig) String() string
type ClusterConfigChange ¶
type ClusterConfigChange struct { ClusterID int32 `protobuf:"varint,1,opt,name=clusterID,proto3" json:"clusterID,omitempty"` Version int32 `protobuf:"varint,2,opt,name=version,proto3" json:"version,omitempty"` // contains filtered or unexported fields }
func (*ClusterConfigChange) Descriptor
deprecated
func (*ClusterConfigChange) Descriptor() ([]byte, []int)
Deprecated: Use ClusterConfigChange.ProtoReflect.Descriptor instead.
func (*ClusterConfigChange) GetClusterID ¶
func (x *ClusterConfigChange) GetClusterID() int32
func (*ClusterConfigChange) GetVersion ¶
func (x *ClusterConfigChange) GetVersion() int32
func (*ClusterConfigChange) ProtoMessage ¶
func (*ClusterConfigChange) ProtoMessage()
func (*ClusterConfigChange) ProtoReflect ¶
func (x *ClusterConfigChange) ProtoReflect() protoreflect.Message
func (*ClusterConfigChange) Reset ¶
func (x *ClusterConfigChange) Reset()
func (*ClusterConfigChange) String ¶
func (x *ClusterConfigChange) String() string
type ClusterConfigListResp ¶
type ClusterConfigListResp struct { ClusterConfigs []*ClusterConfig `protobuf:"bytes,1,rep,name=clusterConfigs,proto3" json:"clusterConfigs,omitempty"` // contains filtered or unexported fields }
func (*ClusterConfigListResp) Descriptor
deprecated
func (*ClusterConfigListResp) Descriptor() ([]byte, []int)
Deprecated: Use ClusterConfigListResp.ProtoReflect.Descriptor instead.
func (*ClusterConfigListResp) GetClusterConfigs ¶
func (x *ClusterConfigListResp) GetClusterConfigs() []*ClusterConfig
func (*ClusterConfigListResp) ProtoMessage ¶
func (*ClusterConfigListResp) ProtoMessage()
func (*ClusterConfigListResp) ProtoReflect ¶
func (x *ClusterConfigListResp) ProtoReflect() protoreflect.Message
func (*ClusterConfigListResp) Reset ¶
func (x *ClusterConfigListResp) Reset()
func (*ClusterConfigListResp) String ¶
func (x *ClusterConfigListResp) String() string
type ClusterConfigReq ¶
type ClusterConfigReq struct { ClusterID int32 `protobuf:"varint,3,opt,name=clusterID,proto3" json:"clusterID,omitempty"` // contains filtered or unexported fields }
func (*ClusterConfigReq) Descriptor
deprecated
func (*ClusterConfigReq) Descriptor() ([]byte, []int)
Deprecated: Use ClusterConfigReq.ProtoReflect.Descriptor instead.
func (*ClusterConfigReq) GetClusterID ¶
func (x *ClusterConfigReq) GetClusterID() int32
func (*ClusterConfigReq) ProtoMessage ¶
func (*ClusterConfigReq) ProtoMessage()
func (*ClusterConfigReq) ProtoReflect ¶
func (x *ClusterConfigReq) ProtoReflect() protoreflect.Message
func (*ClusterConfigReq) Reset ¶
func (x *ClusterConfigReq) Reset()
func (*ClusterConfigReq) String ¶
func (x *ClusterConfigReq) String() string
type ClusterConfigResp ¶
type ClusterConfigResp struct { Version int32 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` // 配置版本 // contains filtered or unexported fields }
func (*ClusterConfigResp) Descriptor
deprecated
func (*ClusterConfigResp) Descriptor() ([]byte, []int)
Deprecated: Use ClusterConfigResp.ProtoReflect.Descriptor instead.
func (*ClusterConfigResp) GetVersion ¶
func (x *ClusterConfigResp) GetVersion() int32
func (*ClusterConfigResp) ProtoMessage ¶
func (*ClusterConfigResp) ProtoMessage()
func (*ClusterConfigResp) ProtoReflect ¶
func (x *ClusterConfigResp) ProtoReflect() protoreflect.Message
func (*ClusterConfigResp) Reset ¶
func (x *ClusterConfigResp) Reset()
func (*ClusterConfigResp) String ¶
func (x *ClusterConfigResp) String() string
type ClusterState ¶
type ClusterState int32
const ( ClusterState_WaitReady ClusterState = 0 ClusterState_Ready ClusterState = 1 ClusterState_Migration ClusterState = 2 )
func (ClusterState) Descriptor ¶
func (ClusterState) Descriptor() protoreflect.EnumDescriptor
func (ClusterState) Enum ¶
func (x ClusterState) Enum() *ClusterState
func (ClusterState) EnumDescriptor
deprecated
func (ClusterState) EnumDescriptor() ([]byte, []int)
Deprecated: Use ClusterState.Descriptor instead.
func (ClusterState) Number ¶
func (x ClusterState) Number() protoreflect.EnumNumber
func (ClusterState) String ¶
func (x ClusterState) String() string
func (ClusterState) Type ¶
func (ClusterState) Type() protoreflect.EnumType
type ConnectInfo ¶
type ConnectInfo struct { NodeID int32 `protobuf:"varint,1,opt,name=nodeID,proto3" json:"nodeID,omitempty"` // 节点ID ClusterID int32 `protobuf:"varint,2,opt,name=clusterID,proto3" json:"clusterID,omitempty"` // 分布式ID // contains filtered or unexported fields }
func (*ConnectInfo) Descriptor
deprecated
func (*ConnectInfo) Descriptor() ([]byte, []int)
Deprecated: Use ConnectInfo.ProtoReflect.Descriptor instead.
func (*ConnectInfo) GetClusterID ¶
func (x *ConnectInfo) GetClusterID() int32
func (*ConnectInfo) GetNodeID ¶
func (x *ConnectInfo) GetNodeID() int32
func (*ConnectInfo) ProtoMessage ¶
func (*ConnectInfo) ProtoMessage()
func (*ConnectInfo) ProtoReflect ¶
func (x *ConnectInfo) ProtoReflect() protoreflect.Message
func (*ConnectInfo) Reset ¶
func (x *ConnectInfo) Reset()
func (*ConnectInfo) String ¶
func (x *ConnectInfo) String() string
type ConnectReq ¶
type ConnectReq struct { NodeID int32 `protobuf:"varint,1,opt,name=nodeID,proto3" json:"nodeID,omitempty"` // 节点ID // contains filtered or unexported fields }
func (*ConnectReq) Descriptor
deprecated
func (*ConnectReq) Descriptor() ([]byte, []int)
Deprecated: Use ConnectReq.ProtoReflect.Descriptor instead.
func (*ConnectReq) GetNodeID ¶
func (x *ConnectReq) GetNodeID() int32
func (*ConnectReq) ProtoMessage ¶
func (*ConnectReq) ProtoMessage()
func (*ConnectReq) ProtoReflect ¶
func (x *ConnectReq) ProtoReflect() protoreflect.Message
func (*ConnectReq) Reset ¶
func (x *ConnectReq) Reset()
func (*ConnectReq) String ¶
func (x *ConnectReq) String() string
type ConnectResp ¶
type ConnectResp struct { Status Status `protobuf:"varint,1,opt,name=status,proto3,enum=Status" json:"status,omitempty"` // 状态 0.失败 1.成功 Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` // 原因 ProxyConfig *ProxyConfig `protobuf:"bytes,3,opt,name=proxyConfig,proto3" json:"proxyConfig,omitempty"` // contains filtered or unexported fields }
func (*ConnectResp) Descriptor
deprecated
func (*ConnectResp) Descriptor() ([]byte, []int)
Deprecated: Use ConnectResp.ProtoReflect.Descriptor instead.
func (*ConnectResp) GetProxyConfig ¶
func (x *ConnectResp) GetProxyConfig() *ProxyConfig
func (*ConnectResp) GetReason ¶
func (x *ConnectResp) GetReason() string
func (*ConnectResp) GetStatus ¶
func (x *ConnectResp) GetStatus() Status
func (*ConnectResp) ProtoMessage ¶
func (*ConnectResp) ProtoMessage()
func (*ConnectResp) ProtoReflect ¶
func (x *ConnectResp) ProtoReflect() protoreflect.Message
func (*ConnectResp) Reset ¶
func (x *ConnectResp) Reset()
func (*ConnectResp) String ¶
func (x *ConnectResp) String() string
type Encoder ¶
type Encoder struct {
// contains filtered or unexported fields
}
Encoder 编码者
func (*Encoder) WriteStringAll ¶
WriteStringAll WriteStringAll
type Exported ¶
type Exported struct { No string `protobuf:"bytes,1,opt,name=no,proto3" json:"no,omitempty"` Slots []byte `protobuf:"bytes,2,opt,name=slots,proto3" json:"slots,omitempty"` // 已导出的slots Path string `protobuf:"bytes,3,opt,name=path,proto3" json:"path,omitempty"` // 对应的备份路径 // contains filtered or unexported fields }
func (*Exported) Descriptor
deprecated
func (*Exported) ProtoMessage ¶
func (*Exported) ProtoMessage()
func (*Exported) ProtoReflect ¶
func (x *Exported) ProtoReflect() protoreflect.Message
type ExportedList ¶
type ExportedList struct { Exported []*Exported `protobuf:"bytes,1,rep,name=exported,proto3" json:"exported,omitempty"` // contains filtered or unexported fields }
func (*ExportedList) Descriptor
deprecated
func (*ExportedList) Descriptor() ([]byte, []int)
Deprecated: Use ExportedList.ProtoReflect.Descriptor instead.
func (*ExportedList) GetExported ¶
func (x *ExportedList) GetExported() []*Exported
func (*ExportedList) ProtoMessage ¶
func (*ExportedList) ProtoMessage()
func (*ExportedList) ProtoReflect ¶
func (x *ExportedList) ProtoReflect() protoreflect.Message
func (*ExportedList) Reset ¶
func (x *ExportedList) Reset()
func (*ExportedList) String ¶
func (x *ExportedList) String() string
type Exporting ¶
type Exporting struct { Slots []byte `protobuf:"bytes,1,opt,name=slots,proto3" json:"slots,omitempty"` // 导出中的slots // contains filtered or unexported fields }
func (*Exporting) Descriptor
deprecated
func (*Exporting) ProtoMessage ¶
func (*Exporting) ProtoMessage()
func (*Exporting) ProtoReflect ¶
func (x *Exporting) ProtoReflect() protoreflect.Message
type Imported ¶
type Imported struct { No string `protobuf:"bytes,1,opt,name=no,proto3" json:"no,omitempty"` Slots []byte `protobuf:"bytes,2,opt,name=slots,proto3" json:"slots,omitempty"` // 已导入的slots // contains filtered or unexported fields }
func (*Imported) Descriptor
deprecated
func (*Imported) ProtoMessage ¶
func (*Imported) ProtoMessage()
func (*Imported) ProtoReflect ¶
func (x *Imported) ProtoReflect() protoreflect.Message
type Node ¶
type Node struct { NodeID int32 `protobuf:"varint,1,opt,name=nodeID,proto3" json:"nodeID,omitempty"` // 节点ID NodeRaftAddr string `protobuf:"bytes,2,opt,name=nodeRaftAddr,proto3" json:"nodeRaftAddr,omitempty"` // 节点Raft地址 NodeAPIAddr string `protobuf:"bytes,3,opt,name=nodeAPIAddr,proto3" json:"nodeAPIAddr,omitempty"` // api地址 类似 http://xxx.xxx.xxx.xxx:8080 NodeRPCAddr string `protobuf:"bytes,4,opt,name=nodeRPCAddr,proto3" json:"nodeRPCAddr,omitempty"` // 节点RPC通讯地址 TcpAddr string `protobuf:"bytes,5,opt,name=tcpAddr,proto3" json:"tcpAddr,omitempty"` // 节点tcp对外地址 WsAddr string `protobuf:"bytes,6,opt,name=wsAddr,proto3" json:"wsAddr,omitempty"` // 节点websocket对外地址 Role Role `protobuf:"varint,7,opt,name=role,proto3,enum=Role" json:"role,omitempty"` Join bool `protobuf:"varint,8,opt,name=join,proto3" json:"join,omitempty"` // 是否是新加入的节点 // contains filtered or unexported fields }
func (*Node) Descriptor
deprecated
func (*Node) GetNodeAPIAddr ¶
func (*Node) GetNodeRPCAddr ¶
func (*Node) GetNodeRaftAddr ¶
func (*Node) GetTcpAddr ¶
func (*Node) ProtoMessage ¶
func (*Node) ProtoMessage()
func (*Node) ProtoReflect ¶
func (x *Node) ProtoReflect() protoreflect.Message
type Ping ¶
type Ping struct { Version int32 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` //配置版本 ClusterID int32 `protobuf:"varint,2,opt,name=clusterID,proto3" json:"clusterID,omitempty"` // 分布式ID LeaderID int32 `protobuf:"varint,3,opt,name=leaderID,proto3" json:"leaderID,omitempty"` // 领导ID TotalVersion int32 `protobuf:"varint,4,opt,name=totalVersion,proto3" json:"totalVersion,omitempty"` // 所有分布式配置的总版本(集群内的所有clusterConfig的version累加的值) // contains filtered or unexported fields }
func (*Ping) Descriptor
deprecated
func (*Ping) GetClusterID ¶
func (*Ping) GetLeaderID ¶
func (*Ping) GetTotalVersion ¶
func (*Ping) GetVersion ¶
func (*Ping) ProtoMessage ¶
func (*Ping) ProtoMessage()
func (*Ping) ProtoReflect ¶
func (x *Ping) ProtoReflect() protoreflect.Message
type Protocol ¶
type Protocol struct { }
Protocol 协议
func (*Protocol) DecodeWithReader ¶
DecodeWithReader 解码
type ProxyConfig ¶
type ProxyConfig struct { UploadSlotBackupURL string `protobuf:"bytes,1,opt,name=uploadSlotBackupURL,proto3" json:"uploadSlotBackupURL,omitempty"` // 上传slot的url地址 DowloadSlotBackupURL string `protobuf:"bytes,2,opt,name=dowloadSlotBackupURL,proto3" json:"dowloadSlotBackupURL,omitempty"` // 下载slot备份的地址 RemoveSlotBackupURL string `protobuf:"bytes,3,opt,name=removeSlotBackupURL,proto3" json:"removeSlotBackupURL,omitempty"` // 移除slot备份的地址 // contains filtered or unexported fields }
func (*ProxyConfig) Descriptor
deprecated
func (*ProxyConfig) Descriptor() ([]byte, []int)
Deprecated: Use ProxyConfig.ProtoReflect.Descriptor instead.
func (*ProxyConfig) GetDowloadSlotBackupURL ¶
func (x *ProxyConfig) GetDowloadSlotBackupURL() string
func (*ProxyConfig) GetRemoveSlotBackupURL ¶
func (x *ProxyConfig) GetRemoveSlotBackupURL() string
func (*ProxyConfig) GetUploadSlotBackupURL ¶
func (x *ProxyConfig) GetUploadSlotBackupURL() string
func (*ProxyConfig) ProtoMessage ¶
func (*ProxyConfig) ProtoMessage()
func (*ProxyConfig) ProtoReflect ¶
func (x *ProxyConfig) ProtoReflect() protoreflect.Message
func (*ProxyConfig) Reset ¶
func (x *ProxyConfig) Reset()
func (*ProxyConfig) String ¶
func (x *ProxyConfig) String() string
type RegisterNodeResp ¶
type RegisterNodeResp struct { Status Status `protobuf:"varint,1,opt,name=status,proto3,enum=Status" json:"status,omitempty"` // 状态 0.失败 1.成功 Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` // 原因 ClusterID int32 `protobuf:"varint,3,opt,name=clusterID,proto3" json:"clusterID,omitempty"` // 分布式ID // contains filtered or unexported fields }
func (*RegisterNodeResp) Descriptor
deprecated
func (*RegisterNodeResp) Descriptor() ([]byte, []int)
Deprecated: Use RegisterNodeResp.ProtoReflect.Descriptor instead.
func (*RegisterNodeResp) GetClusterID ¶
func (x *RegisterNodeResp) GetClusterID() int32
func (*RegisterNodeResp) GetReason ¶
func (x *RegisterNodeResp) GetReason() string
func (*RegisterNodeResp) GetStatus ¶
func (x *RegisterNodeResp) GetStatus() Status
func (*RegisterNodeResp) ProtoMessage ¶
func (*RegisterNodeResp) ProtoMessage()
func (*RegisterNodeResp) ProtoReflect ¶
func (x *RegisterNodeResp) ProtoReflect() protoreflect.Message
func (*RegisterNodeResp) Reset ¶
func (x *RegisterNodeResp) Reset()
func (*RegisterNodeResp) String ¶
func (x *RegisterNodeResp) String() string
type Role ¶
type Role int32
func (Role) Descriptor ¶
func (Role) Descriptor() protoreflect.EnumDescriptor
func (Role) EnumDescriptor
deprecated
func (Role) Number ¶
func (x Role) Number() protoreflect.EnumNumber
func (Role) Type ¶
func (Role) Type() protoreflect.EnumType
type Status ¶
type Status int32
func (Status) Descriptor ¶
func (Status) Descriptor() protoreflect.EnumDescriptor
func (Status) EnumDescriptor
deprecated
func (Status) Number ¶
func (x Status) Number() protoreflect.EnumNumber
func (Status) Type ¶
func (Status) Type() protoreflect.EnumType
type StatusResp ¶
type StatusResp struct { Status Status `protobuf:"varint,1,opt,name=status,proto3,enum=Status" json:"status,omitempty"` // 状态 0.失败 1.成功 Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"` // 原因 // contains filtered or unexported fields }
func (*StatusResp) Descriptor
deprecated
func (*StatusResp) Descriptor() ([]byte, []int)
Deprecated: Use StatusResp.ProtoReflect.Descriptor instead.
func (*StatusResp) GetReason ¶
func (x *StatusResp) GetReason() string
func (*StatusResp) GetStatus ¶
func (x *StatusResp) GetStatus() Status
func (*StatusResp) ProtoMessage ¶
func (*StatusResp) ProtoMessage()
func (*StatusResp) ProtoReflect ¶
func (x *StatusResp) ProtoReflect() protoreflect.Message
func (*StatusResp) Reset ¶
func (x *StatusResp) Reset()
func (*StatusResp) String ¶
func (x *StatusResp) String() string