1 Star 0 Fork 0

StudySpace/uess-protobuf

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
uess-cluster.pb.go 16.75 KB
一键复制 编辑 原始数据 按行查看 历史
木子金兑 提交于 2023-05-24 10:13 . feat: 集群详情列表
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.30.0
// protoc v4.23.1
// source: uess-cluster.proto
package pb
import (
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// 主机注册 GET token_option /api/v1/cluster/detail
type UESSClusterDetailRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
}
func (x *UESSClusterDetailRequest) Reset() {
*x = UESSClusterDetailRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_uess_cluster_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UESSClusterDetailRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UESSClusterDetailRequest) ProtoMessage() {}
func (x *UESSClusterDetailRequest) ProtoReflect() protoreflect.Message {
mi := &file_uess_cluster_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UESSClusterDetailRequest.ProtoReflect.Descriptor instead.
func (*UESSClusterDetailRequest) Descriptor() ([]byte, []int) {
return file_uess_cluster_proto_rawDescGZIP(), []int{0}
}
type UESSClusterDetailResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
Code int32 `protobuf:"varint,2,opt,name=code,proto3" json:"code,omitempty"`
HostList []*UESSClusterDetailResponse_HostItem `protobuf:"bytes,3,rep,name=host_list,json=hostList,proto3" json:"host_list,omitempty"`
}
func (x *UESSClusterDetailResponse) Reset() {
*x = UESSClusterDetailResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_uess_cluster_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UESSClusterDetailResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UESSClusterDetailResponse) ProtoMessage() {}
func (x *UESSClusterDetailResponse) ProtoReflect() protoreflect.Message {
mi := &file_uess_cluster_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UESSClusterDetailResponse.ProtoReflect.Descriptor instead.
func (*UESSClusterDetailResponse) Descriptor() ([]byte, []int) {
return file_uess_cluster_proto_rawDescGZIP(), []int{1}
}
func (x *UESSClusterDetailResponse) GetMsg() string {
if x != nil {
return x.Msg
}
return ""
}
func (x *UESSClusterDetailResponse) GetCode() int32 {
if x != nil {
return x.Code
}
return 0
}
func (x *UESSClusterDetailResponse) GetHostList() []*UESSClusterDetailResponse_HostItem {
if x != nil {
return x.HostList
}
return nil
}
// 主机注册 POST token_option /api/v1/cluster/on_register
type UESSHostRegisterRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
HostIp string `protobuf:"bytes,1,opt,name=host_ip,json=hostIp,proto3" json:"host_ip,omitempty"`
Port uint32 `protobuf:"varint,2,opt,name=port,proto3" json:"port,omitempty"`
}
func (x *UESSHostRegisterRequest) Reset() {
*x = UESSHostRegisterRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_uess_cluster_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UESSHostRegisterRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UESSHostRegisterRequest) ProtoMessage() {}
func (x *UESSHostRegisterRequest) ProtoReflect() protoreflect.Message {
mi := &file_uess_cluster_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UESSHostRegisterRequest.ProtoReflect.Descriptor instead.
func (*UESSHostRegisterRequest) Descriptor() ([]byte, []int) {
return file_uess_cluster_proto_rawDescGZIP(), []int{2}
}
func (x *UESSHostRegisterRequest) GetHostIp() string {
if x != nil {
return x.HostIp
}
return ""
}
func (x *UESSHostRegisterRequest) GetPort() uint32 {
if x != nil {
return x.Port
}
return 0
}
type UESSHostRegisterResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
Code int32 `protobuf:"varint,2,opt,name=code,proto3" json:"code,omitempty"`
}
func (x *UESSHostRegisterResponse) Reset() {
*x = UESSHostRegisterResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_uess_cluster_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UESSHostRegisterResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UESSHostRegisterResponse) ProtoMessage() {}
func (x *UESSHostRegisterResponse) ProtoReflect() protoreflect.Message {
mi := &file_uess_cluster_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UESSHostRegisterResponse.ProtoReflect.Descriptor instead.
func (*UESSHostRegisterResponse) Descriptor() ([]byte, []int) {
return file_uess_cluster_proto_rawDescGZIP(), []int{3}
}
func (x *UESSHostRegisterResponse) GetMsg() string {
if x != nil {
return x.Msg
}
return ""
}
func (x *UESSHostRegisterResponse) GetCode() int32 {
if x != nil {
return x.Code
}
return 0
}
type UESSClusterDetailResponse_HostItem struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Ip string `protobuf:"bytes,1,opt,name=ip,proto3" json:"ip,omitempty"`
CpuPercent float32 `protobuf:"fixed32,2,opt,name=cpu_percent,json=cpuPercent,proto3" json:"cpu_percent,omitempty"`
FreeMemory float32 `protobuf:"fixed32,3,opt,name=free_memory,json=freeMemory,proto3" json:"free_memory,omitempty"`
Role string `protobuf:"bytes,4,opt,name=role,proto3" json:"role,omitempty"` // 角色
JoinTime string `protobuf:"bytes,5,opt,name=join_time,json=joinTime,proto3" json:"join_time,omitempty"` // 加入时间
HttpPort uint32 `protobuf:"varint,6,opt,name=http_port,json=httpPort,proto3" json:"http_port,omitempty"`
RpcPort uint32 `protobuf:"varint,7,opt,name=rpc_port,json=rpcPort,proto3" json:"rpc_port,omitempty"`
Grade uint32 `protobuf:"varint,8,opt,name=grade,proto3" json:"grade,omitempty"`
HeartTime string `protobuf:"bytes,9,opt,name=heart_time,json=heartTime,proto3" json:"heart_time,omitempty"`
Status string `protobuf:"bytes,10,opt,name=status,proto3" json:"status,omitempty"`
}
func (x *UESSClusterDetailResponse_HostItem) Reset() {
*x = UESSClusterDetailResponse_HostItem{}
if protoimpl.UnsafeEnabled {
mi := &file_uess_cluster_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UESSClusterDetailResponse_HostItem) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UESSClusterDetailResponse_HostItem) ProtoMessage() {}
func (x *UESSClusterDetailResponse_HostItem) ProtoReflect() protoreflect.Message {
mi := &file_uess_cluster_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UESSClusterDetailResponse_HostItem.ProtoReflect.Descriptor instead.
func (*UESSClusterDetailResponse_HostItem) Descriptor() ([]byte, []int) {
return file_uess_cluster_proto_rawDescGZIP(), []int{1, 0}
}
func (x *UESSClusterDetailResponse_HostItem) GetIp() string {
if x != nil {
return x.Ip
}
return ""
}
func (x *UESSClusterDetailResponse_HostItem) GetCpuPercent() float32 {
if x != nil {
return x.CpuPercent
}
return 0
}
func (x *UESSClusterDetailResponse_HostItem) GetFreeMemory() float32 {
if x != nil {
return x.FreeMemory
}
return 0
}
func (x *UESSClusterDetailResponse_HostItem) GetRole() string {
if x != nil {
return x.Role
}
return ""
}
func (x *UESSClusterDetailResponse_HostItem) GetJoinTime() string {
if x != nil {
return x.JoinTime
}
return ""
}
func (x *UESSClusterDetailResponse_HostItem) GetHttpPort() uint32 {
if x != nil {
return x.HttpPort
}
return 0
}
func (x *UESSClusterDetailResponse_HostItem) GetRpcPort() uint32 {
if x != nil {
return x.RpcPort
}
return 0
}
func (x *UESSClusterDetailResponse_HostItem) GetGrade() uint32 {
if x != nil {
return x.Grade
}
return 0
}
func (x *UESSClusterDetailResponse_HostItem) GetHeartTime() string {
if x != nil {
return x.HeartTime
}
return ""
}
func (x *UESSClusterDetailResponse_HostItem) GetStatus() string {
if x != nil {
return x.Status
}
return ""
}
var File_uess_cluster_proto protoreflect.FileDescriptor
var file_uess_cluster_proto_rawDesc = []byte{
0x0a, 0x12, 0x75, 0x65, 0x73, 0x73, 0x2d, 0x63, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x2e, 0x70,
0x72, 0x6f, 0x74, 0x6f, 0x12, 0x02, 0x70, 0x62, 0x22, 0x1a, 0x0a, 0x18, 0x55, 0x45, 0x53, 0x53,
0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x71,
0x75, 0x65, 0x73, 0x74, 0x22, 0x9b, 0x03, 0x0a, 0x19, 0x55, 0x45, 0x53, 0x53, 0x43, 0x6c, 0x75,
0x73, 0x74, 0x65, 0x72, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
0x03, 0x6d, 0x73, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x05, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x43, 0x0a, 0x09, 0x68, 0x6f, 0x73, 0x74,
0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x70, 0x62,
0x2e, 0x55, 0x45, 0x53, 0x53, 0x43, 0x6c, 0x75, 0x73, 0x74, 0x65, 0x72, 0x44, 0x65, 0x74, 0x61,
0x69, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x6f, 0x73, 0x74, 0x49,
0x74, 0x65, 0x6d, 0x52, 0x08, 0x68, 0x6f, 0x73, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x1a, 0x92, 0x02,
0x0a, 0x08, 0x48, 0x6f, 0x73, 0x74, 0x49, 0x74, 0x65, 0x6d, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x70,
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x70, 0x12, 0x1f, 0x0a, 0x0b, 0x63, 0x70,
0x75, 0x5f, 0x70, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x02, 0x52,
0x0a, 0x63, 0x70, 0x75, 0x50, 0x65, 0x72, 0x63, 0x65, 0x6e, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x66,
0x72, 0x65, 0x65, 0x5f, 0x6d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02,
0x52, 0x0a, 0x66, 0x72, 0x65, 0x65, 0x4d, 0x65, 0x6d, 0x6f, 0x72, 0x79, 0x12, 0x12, 0x0a, 0x04,
0x72, 0x6f, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x72, 0x6f, 0x6c, 0x65,
0x12, 0x1b, 0x0a, 0x09, 0x6a, 0x6f, 0x69, 0x6e, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x05, 0x20,
0x01, 0x28, 0x09, 0x52, 0x08, 0x6a, 0x6f, 0x69, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1b, 0x0a,
0x09, 0x68, 0x74, 0x74, 0x70, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0d,
0x52, 0x08, 0x68, 0x74, 0x74, 0x70, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x72, 0x70,
0x63, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x07, 0x72, 0x70,
0x63, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x67, 0x72, 0x61, 0x64, 0x65, 0x18, 0x08,
0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x67, 0x72, 0x61, 0x64, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x68,
0x65, 0x61, 0x72, 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52,
0x09, 0x68, 0x65, 0x61, 0x72, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74,
0x61, 0x74, 0x75, 0x73, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74,
0x75, 0x73, 0x22, 0x46, 0x0a, 0x17, 0x55, 0x45, 0x53, 0x53, 0x48, 0x6f, 0x73, 0x74, 0x52, 0x65,
0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x17, 0x0a,
0x07, 0x68, 0x6f, 0x73, 0x74, 0x5f, 0x69, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06,
0x68, 0x6f, 0x73, 0x74, 0x49, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02,
0x20, 0x01, 0x28, 0x0d, 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x22, 0x40, 0x0a, 0x18, 0x55, 0x45,
0x53, 0x53, 0x48, 0x6f, 0x73, 0x74, 0x52, 0x65, 0x67, 0x69, 0x73, 0x74, 0x65, 0x72, 0x52, 0x65,
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20,
0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, 0x64, 0x65,
0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x42, 0x06, 0x5a, 0x04,
0x2e, 0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
file_uess_cluster_proto_rawDescOnce sync.Once
file_uess_cluster_proto_rawDescData = file_uess_cluster_proto_rawDesc
)
func file_uess_cluster_proto_rawDescGZIP() []byte {
file_uess_cluster_proto_rawDescOnce.Do(func() {
file_uess_cluster_proto_rawDescData = protoimpl.X.CompressGZIP(file_uess_cluster_proto_rawDescData)
})
return file_uess_cluster_proto_rawDescData
}
var file_uess_cluster_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
var file_uess_cluster_proto_goTypes = []interface{}{
(*UESSClusterDetailRequest)(nil), // 0: pb.UESSClusterDetailRequest
(*UESSClusterDetailResponse)(nil), // 1: pb.UESSClusterDetailResponse
(*UESSHostRegisterRequest)(nil), // 2: pb.UESSHostRegisterRequest
(*UESSHostRegisterResponse)(nil), // 3: pb.UESSHostRegisterResponse
(*UESSClusterDetailResponse_HostItem)(nil), // 4: pb.UESSClusterDetailResponse.HostItem
}
var file_uess_cluster_proto_depIdxs = []int32{
4, // 0: pb.UESSClusterDetailResponse.host_list:type_name -> pb.UESSClusterDetailResponse.HostItem
1, // [1:1] is the sub-list for method output_type
1, // [1:1] is the sub-list for method input_type
1, // [1:1] is the sub-list for extension type_name
1, // [1:1] is the sub-list for extension extendee
0, // [0:1] is the sub-list for field type_name
}
func init() { file_uess_cluster_proto_init() }
func file_uess_cluster_proto_init() {
if File_uess_cluster_proto != nil {
return
}
if !protoimpl.UnsafeEnabled {
file_uess_cluster_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UESSClusterDetailRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_uess_cluster_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UESSClusterDetailResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_uess_cluster_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UESSHostRegisterRequest); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_uess_cluster_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UESSHostRegisterResponse); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
file_uess_cluster_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
switch v := v.(*UESSClusterDetailResponse_HostItem); i {
case 0:
return &v.state
case 1:
return &v.sizeCache
case 2:
return &v.unknownFields
default:
return nil
}
}
}
type x struct{}
out := protoimpl.TypeBuilder{
File: protoimpl.DescBuilder{
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
RawDescriptor: file_uess_cluster_proto_rawDesc,
NumEnums: 0,
NumMessages: 5,
NumExtensions: 0,
NumServices: 0,
},
GoTypes: file_uess_cluster_proto_goTypes,
DependencyIndexes: file_uess_cluster_proto_depIdxs,
MessageInfos: file_uess_cluster_proto_msgTypes,
}.Build()
File_uess_cluster_proto = out.File
file_uess_cluster_proto_rawDesc = nil
file_uess_cluster_proto_goTypes = nil
file_uess_cluster_proto_depIdxs = nil
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/lrayt-study-space/uess-protobuf.git
git@gitee.com:lrayt-study-space/uess-protobuf.git
lrayt-study-space
uess-protobuf
uess-protobuf
v0.1.9

搜索帮助