msaObserver

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2021 License: MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_proto_msa_observer_proto protoreflect.FileDescriptor
View Source
var Observer_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "msaObserver.Observer",
	HandlerType: (*ObserverServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "PushFirst",
			Handler:    _Observer_PushFirst_Handler,
		},
		{
			MethodName: "PushStats",
			Handler:    _Observer_PushStats_Handler,
		},
		{
			MethodName: "PushStatus",
			Handler:    _Observer_PushStatus_Handler,
		},
		{
			MethodName: "Who",
			Handler:    _Observer_Who_Handler,
		},
		{
			MethodName: "RestartService",
			Handler:    _Observer_RestartService_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "msa/proto/msaObserver.proto",
}

Observer_ServiceDesc is the grpc.ServiceDesc for Observer service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterObserverServer

func RegisterObserverServer(s grpc.ServiceRegistrar, srv ObserverServer)

Types

type Info

type Info struct {
	Host      string `protobuf:"bytes,1,opt,name=Host,proto3" json:"Host,omitempty"`
	Port      int32  `protobuf:"varint,2,opt,name=Port,proto3" json:"Port,omitempty"`
	Key       string `protobuf:"bytes,3,opt,name=Key,proto3" json:"Key,omitempty"`
	GroupType string `protobuf:"bytes,4,opt,name=GroupType,proto3" json:"GroupType,omitempty"`
	// contains filtered or unexported fields
}

func (*Info) Descriptor deprecated

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

Deprecated: Use Info.ProtoReflect.Descriptor instead.

func (*Info) GetGroupType

func (x *Info) GetGroupType() string

func (*Info) GetHost

func (x *Info) GetHost() string

func (*Info) GetKey

func (x *Info) GetKey() string

func (*Info) GetPort

func (x *Info) GetPort() int32

func (*Info) ProtoMessage

func (*Info) ProtoMessage()

func (*Info) ProtoReflect

func (x *Info) ProtoReflect() protoreflect.Message

func (*Info) Reset

func (x *Info) Reset()

func (*Info) String

func (x *Info) String() string

type ObserverClient

type ObserverClient interface {
	PushFirst(ctx context.Context, in *RequestPushFirst, opts ...grpc.CallOption) (*ResponsePushFirst, error)
	PushStats(ctx context.Context, in *RequestPushStats, opts ...grpc.CallOption) (*Response, error)
	PushStatus(ctx context.Context, in *RequestPushStatus, opts ...grpc.CallOption) (*Response, error)
	Who(ctx context.Context, in *RequestWho, opts ...grpc.CallOption) (*ResponseWho, error)
	RestartService(ctx context.Context, in *RequestRestartService, opts ...grpc.CallOption) (*Response, error)
}

ObserverClient is the client API for Observer service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewObserverClient

func NewObserverClient(cc grpc.ClientConnInterface) ObserverClient

type ObserverServer

type ObserverServer interface {
	PushFirst(context.Context, *RequestPushFirst) (*ResponsePushFirst, error)
	PushStats(context.Context, *RequestPushStats) (*Response, error)
	PushStatus(context.Context, *RequestPushStatus) (*Response, error)
	Who(context.Context, *RequestWho) (*ResponseWho, error)
	RestartService(context.Context, *RequestRestartService) (*Response, error)
	// contains filtered or unexported methods
}

ObserverServer is the server API for Observer service. All implementations must embed UnimplementedObserverServer for forward compatibility

type RequestPushFirst

type RequestPushFirst struct {
	Host string `protobuf:"bytes,1,opt,name=Host,proto3" json:"Host,omitempty"`
	Port int32  `protobuf:"varint,2,opt,name=Port,proto3" json:"Port,omitempty"`
	Key  string `protobuf:"bytes,3,opt,name=Key,proto3" json:"Key,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestPushFirst) Descriptor deprecated

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

Deprecated: Use RequestPushFirst.ProtoReflect.Descriptor instead.

func (*RequestPushFirst) GetHost

func (x *RequestPushFirst) GetHost() string

func (*RequestPushFirst) GetKey

func (x *RequestPushFirst) GetKey() string

func (*RequestPushFirst) GetPort

func (x *RequestPushFirst) GetPort() int32

func (*RequestPushFirst) ProtoMessage

func (*RequestPushFirst) ProtoMessage()

func (*RequestPushFirst) ProtoReflect

func (x *RequestPushFirst) ProtoReflect() protoreflect.Message

func (*RequestPushFirst) Reset

func (x *RequestPushFirst) Reset()

func (*RequestPushFirst) String

func (x *RequestPushFirst) String() string

type RequestPushStats

type RequestPushStats struct {
	Key    string  `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	CurCpu float32 `protobuf:"fixed32,2,opt,name=CurCpu,proto3" json:"CurCpu,omitempty"`
	MaxCpu float32 `protobuf:"fixed32,3,opt,name=MaxCpu,proto3" json:"MaxCpu,omitempty"`
	CurRam float32 `protobuf:"fixed32,4,opt,name=CurRam,proto3" json:"CurRam,omitempty"`
	MaxRam float32 `protobuf:"fixed32,5,opt,name=MaxRam,proto3" json:"MaxRam,omitempty"`
	CurHdd float32 `protobuf:"fixed32,6,opt,name=CurHdd,proto3" json:"CurHdd,omitempty"`
	MaxHdd float32 `protobuf:"fixed32,7,opt,name=MaxHdd,proto3" json:"MaxHdd,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestPushStats) Descriptor deprecated

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

Deprecated: Use RequestPushStats.ProtoReflect.Descriptor instead.

func (*RequestPushStats) GetCurCpu

func (x *RequestPushStats) GetCurCpu() float32

func (*RequestPushStats) GetCurHdd

func (x *RequestPushStats) GetCurHdd() float32

func (*RequestPushStats) GetCurRam

func (x *RequestPushStats) GetCurRam() float32

func (*RequestPushStats) GetKey

func (x *RequestPushStats) GetKey() string

func (*RequestPushStats) GetMaxCpu

func (x *RequestPushStats) GetMaxCpu() float32

func (*RequestPushStats) GetMaxHdd

func (x *RequestPushStats) GetMaxHdd() float32

func (*RequestPushStats) GetMaxRam

func (x *RequestPushStats) GetMaxRam() float32

func (*RequestPushStats) ProtoMessage

func (*RequestPushStats) ProtoMessage()

func (*RequestPushStats) ProtoReflect

func (x *RequestPushStats) ProtoReflect() protoreflect.Message

func (*RequestPushStats) Reset

func (x *RequestPushStats) Reset()

func (*RequestPushStats) String

func (x *RequestPushStats) String() string

type RequestPushStatus

type RequestPushStatus struct {
	Key    string                 `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	IsNew  bool                   `protobuf:"varint,2,opt,name=IsNew,proto3" json:"IsNew,omitempty"`
	Status msaUtils.StatusService `protobuf:"varint,3,opt,name=Status,proto3,enum=msaUtils.StatusService" json:"Status,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestPushStatus) Descriptor deprecated

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

Deprecated: Use RequestPushStatus.ProtoReflect.Descriptor instead.

func (*RequestPushStatus) GetIsNew

func (x *RequestPushStatus) GetIsNew() bool

func (*RequestPushStatus) GetKey

func (x *RequestPushStatus) GetKey() string

func (*RequestPushStatus) GetStatus

func (x *RequestPushStatus) GetStatus() msaUtils.StatusService

func (*RequestPushStatus) ProtoMessage

func (*RequestPushStatus) ProtoMessage()

func (*RequestPushStatus) ProtoReflect

func (x *RequestPushStatus) ProtoReflect() protoreflect.Message

func (*RequestPushStatus) Reset

func (x *RequestPushStatus) Reset()

func (*RequestPushStatus) String

func (x *RequestPushStatus) String() string

type RequestRestartService

type RequestRestartService struct {
	Key string `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestRestartService) Descriptor deprecated

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

Deprecated: Use RequestRestartService.ProtoReflect.Descriptor instead.

func (*RequestRestartService) GetKey

func (x *RequestRestartService) GetKey() string

func (*RequestRestartService) ProtoMessage

func (*RequestRestartService) ProtoMessage()

func (*RequestRestartService) ProtoReflect

func (x *RequestRestartService) ProtoReflect() protoreflect.Message

func (*RequestRestartService) Reset

func (x *RequestRestartService) Reset()

func (*RequestRestartService) String

func (x *RequestRestartService) String() string

type RequestWho

type RequestWho struct {
	GroupType string `protobuf:"bytes,1,opt,name=GroupType,proto3" json:"GroupType,omitempty"`
	// contains filtered or unexported fields
}

func (*RequestWho) Descriptor deprecated

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

Deprecated: Use RequestWho.ProtoReflect.Descriptor instead.

func (*RequestWho) GetGroupType

func (x *RequestWho) GetGroupType() string

func (*RequestWho) ProtoMessage

func (*RequestWho) ProtoMessage()

func (*RequestWho) ProtoReflect

func (x *RequestWho) ProtoReflect() protoreflect.Message

func (*RequestWho) Reset

func (x *RequestWho) Reset()

func (*RequestWho) String

func (x *RequestWho) String() string

type Response

type Response struct {
	Success bool `protobuf:"varint,1,opt,name=Success,proto3" json:"Success,omitempty"`
	// contains filtered or unexported fields
}

func (*Response) Descriptor deprecated

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

Deprecated: Use Response.ProtoReflect.Descriptor instead.

func (*Response) GetSuccess

func (x *Response) GetSuccess() bool

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) ProtoReflect

func (x *Response) ProtoReflect() protoreflect.Message

func (*Response) Reset

func (x *Response) Reset()

func (*Response) String

func (x *Response) String() string

type ResponsePushFirst

type ResponsePushFirst struct {
	Dependents []*Info `protobuf:"bytes,1,rep,name=Dependents,proto3" json:"Dependents,omitempty"`
	// contains filtered or unexported fields
}

func (*ResponsePushFirst) Descriptor deprecated

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

Deprecated: Use ResponsePushFirst.ProtoReflect.Descriptor instead.

func (*ResponsePushFirst) GetDependents

func (x *ResponsePushFirst) GetDependents() []*Info

func (*ResponsePushFirst) ProtoMessage

func (*ResponsePushFirst) ProtoMessage()

func (*ResponsePushFirst) ProtoReflect

func (x *ResponsePushFirst) ProtoReflect() protoreflect.Message

func (*ResponsePushFirst) Reset

func (x *ResponsePushFirst) Reset()

func (*ResponsePushFirst) String

func (x *ResponsePushFirst) String() string

type ResponseWho

type ResponseWho struct {
	Key string `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	// contains filtered or unexported fields
}

func (*ResponseWho) Descriptor deprecated

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

Deprecated: Use ResponseWho.ProtoReflect.Descriptor instead.

func (*ResponseWho) GetKey

func (x *ResponseWho) GetKey() string

func (*ResponseWho) ProtoMessage

func (*ResponseWho) ProtoMessage()

func (*ResponseWho) ProtoReflect

func (x *ResponseWho) ProtoReflect() protoreflect.Message

func (*ResponseWho) Reset

func (x *ResponseWho) Reset()

func (*ResponseWho) String

func (x *ResponseWho) String() string

type UnimplementedObserverServer

type UnimplementedObserverServer struct {
}

UnimplementedObserverServer must be embedded to have forward compatible implementations.

func (UnimplementedObserverServer) PushFirst

func (UnimplementedObserverServer) PushStats

func (UnimplementedObserverServer) PushStatus

func (UnimplementedObserverServer) RestartService

func (UnimplementedObserverServer) Who

type UnsafeObserverServer

type UnsafeObserverServer interface {
	// contains filtered or unexported methods
}

UnsafeObserverServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ObserverServer will result in compilation errors.

Jump to

Keyboard shortcuts

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