Documentation
¶
Index ¶
- Variables
- func RegisterStatisticsServer(s grpc.ServiceRegistrar, srv StatisticsServer)
- type CPUAverage
- func (*CPUAverage) Descriptor() ([]byte, []int)deprecated
- func (x *CPUAverage) GetIdle() string
- func (x *CPUAverage) GetStatus() string
- func (x *CPUAverage) GetSys() string
- func (x *CPUAverage) GetUser() string
- func (*CPUAverage) ProtoMessage()
- func (x *CPUAverage) ProtoReflect() protoreflect.Message
- func (x *CPUAverage) Reset()
- func (x *CPUAverage) String() string
- type LoadAverage
- func (*LoadAverage) Descriptor() ([]byte, []int)deprecated
- func (x *LoadAverage) GetFifteenMin() string
- func (x *LoadAverage) GetFiveMin() string
- func (x *LoadAverage) GetOneMin() string
- func (x *LoadAverage) GetStatus() string
- func (*LoadAverage) ProtoMessage()
- func (x *LoadAverage) ProtoReflect() protoreflect.Message
- func (x *LoadAverage) Reset()
- func (x *LoadAverage) String() string
- type StatisticsClient
- type StatisticsResponse
- func (*StatisticsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *StatisticsResponse) GetCp() *CPUAverage
- func (x *StatisticsResponse) GetLa() *LoadAverage
- func (x *StatisticsResponse) GetStatus() string
- func (*StatisticsResponse) ProtoMessage()
- func (x *StatisticsResponse) ProtoReflect() protoreflect.Message
- func (x *StatisticsResponse) Reset()
- func (x *StatisticsResponse) String() string
- type StatisticsServer
- type Statistics_ListStatisticsClient
- type Statistics_ListStatisticsServer
- type SubscriptionRequest
- func (*SubscriptionRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SubscriptionRequest) GetDepth() int64
- func (x *SubscriptionRequest) GetPeriod() *durationpb.Duration
- func (*SubscriptionRequest) ProtoMessage()
- func (x *SubscriptionRequest) ProtoReflect() protoreflect.Message
- func (x *SubscriptionRequest) Reset()
- func (x *SubscriptionRequest) String() string
- type UnimplementedStatisticsServer
- type UnsafeStatisticsServer
Constants ¶
This section is empty.
Variables ¶
var File_Service_proto protoreflect.FileDescriptor
var Statistics_ServiceDesc = grpc.ServiceDesc{ ServiceName: "service.Statistics", HandlerType: (*StatisticsServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "ListStatistics", Handler: _Statistics_ListStatistics_Handler, ServerStreams: true, }, }, Metadata: "Service.proto", }
Statistics_ServiceDesc is the grpc.ServiceDesc for Statistics service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterStatisticsServer ¶
func RegisterStatisticsServer(s grpc.ServiceRegistrar, srv StatisticsServer)
Types ¶
type CPUAverage ¶
type CPUAverage struct { Status string `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` User string `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"` Sys string `protobuf:"bytes,3,opt,name=sys,proto3" json:"sys,omitempty"` Idle string `protobuf:"bytes,4,opt,name=idle,proto3" json:"idle,omitempty"` // contains filtered or unexported fields }
func (*CPUAverage) Descriptor
deprecated
func (*CPUAverage) Descriptor() ([]byte, []int)
Deprecated: Use CPUAverage.ProtoReflect.Descriptor instead.
func (*CPUAverage) GetIdle ¶
func (x *CPUAverage) GetIdle() string
func (*CPUAverage) GetStatus ¶
func (x *CPUAverage) GetStatus() string
func (*CPUAverage) GetSys ¶
func (x *CPUAverage) GetSys() string
func (*CPUAverage) GetUser ¶
func (x *CPUAverage) GetUser() string
func (*CPUAverage) ProtoMessage ¶
func (*CPUAverage) ProtoMessage()
func (*CPUAverage) ProtoReflect ¶
func (x *CPUAverage) ProtoReflect() protoreflect.Message
func (*CPUAverage) Reset ¶
func (x *CPUAverage) Reset()
func (*CPUAverage) String ¶
func (x *CPUAverage) String() string
type LoadAverage ¶
type LoadAverage struct { Status string `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` OneMin string `protobuf:"bytes,2,opt,name=oneMin,proto3" json:"oneMin,omitempty"` FiveMin string `protobuf:"bytes,3,opt,name=fiveMin,proto3" json:"fiveMin,omitempty"` FifteenMin string `protobuf:"bytes,4,opt,name=fifteenMin,proto3" json:"fifteenMin,omitempty"` // contains filtered or unexported fields }
func (*LoadAverage) Descriptor
deprecated
func (*LoadAverage) Descriptor() ([]byte, []int)
Deprecated: Use LoadAverage.ProtoReflect.Descriptor instead.
func (*LoadAverage) GetFifteenMin ¶
func (x *LoadAverage) GetFifteenMin() string
func (*LoadAverage) GetFiveMin ¶
func (x *LoadAverage) GetFiveMin() string
func (*LoadAverage) GetOneMin ¶
func (x *LoadAverage) GetOneMin() string
func (*LoadAverage) GetStatus ¶
func (x *LoadAverage) GetStatus() string
func (*LoadAverage) ProtoMessage ¶
func (*LoadAverage) ProtoMessage()
func (*LoadAverage) ProtoReflect ¶
func (x *LoadAverage) ProtoReflect() protoreflect.Message
func (*LoadAverage) Reset ¶
func (x *LoadAverage) Reset()
func (*LoadAverage) String ¶
func (x *LoadAverage) String() string
type StatisticsClient ¶
type StatisticsClient interface {
ListStatistics(ctx context.Context, in *SubscriptionRequest, opts ...grpc.CallOption) (Statistics_ListStatisticsClient, error)
}
StatisticsClient is the client API for Statistics 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 NewStatisticsClient ¶
func NewStatisticsClient(cc grpc.ClientConnInterface) StatisticsClient
type StatisticsResponse ¶
type StatisticsResponse struct { Status string `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` La *LoadAverage `protobuf:"bytes,2,opt,name=la,proto3" json:"la,omitempty"` Cp *CPUAverage `protobuf:"bytes,3,opt,name=cp,proto3" json:"cp,omitempty"` // contains filtered or unexported fields }
func (*StatisticsResponse) Descriptor
deprecated
func (*StatisticsResponse) Descriptor() ([]byte, []int)
Deprecated: Use StatisticsResponse.ProtoReflect.Descriptor instead.
func (*StatisticsResponse) GetCp ¶
func (x *StatisticsResponse) GetCp() *CPUAverage
func (*StatisticsResponse) GetLa ¶
func (x *StatisticsResponse) GetLa() *LoadAverage
func (*StatisticsResponse) GetStatus ¶
func (x *StatisticsResponse) GetStatus() string
func (*StatisticsResponse) ProtoMessage ¶
func (*StatisticsResponse) ProtoMessage()
func (*StatisticsResponse) ProtoReflect ¶
func (x *StatisticsResponse) ProtoReflect() protoreflect.Message
func (*StatisticsResponse) Reset ¶
func (x *StatisticsResponse) Reset()
func (*StatisticsResponse) String ¶
func (x *StatisticsResponse) String() string
type StatisticsServer ¶
type StatisticsServer interface { ListStatistics(*SubscriptionRequest, Statistics_ListStatisticsServer) error // contains filtered or unexported methods }
StatisticsServer is the server API for Statistics service. All implementations must embed UnimplementedStatisticsServer for forward compatibility
type Statistics_ListStatisticsClient ¶
type Statistics_ListStatisticsClient interface { Recv() (*StatisticsResponse, error) grpc.ClientStream }
type Statistics_ListStatisticsServer ¶
type Statistics_ListStatisticsServer interface { Send(*StatisticsResponse) error grpc.ServerStream }
type SubscriptionRequest ¶
type SubscriptionRequest struct { Period *durationpb.Duration `protobuf:"bytes,1,opt,name=period,proto3" json:"period,omitempty"` Depth int64 `protobuf:"varint,2,opt,name=depth,proto3" json:"depth,omitempty"` // contains filtered or unexported fields }
func (*SubscriptionRequest) Descriptor
deprecated
func (*SubscriptionRequest) Descriptor() ([]byte, []int)
Deprecated: Use SubscriptionRequest.ProtoReflect.Descriptor instead.
func (*SubscriptionRequest) GetDepth ¶
func (x *SubscriptionRequest) GetDepth() int64
func (*SubscriptionRequest) GetPeriod ¶
func (x *SubscriptionRequest) GetPeriod() *durationpb.Duration
func (*SubscriptionRequest) ProtoMessage ¶
func (*SubscriptionRequest) ProtoMessage()
func (*SubscriptionRequest) ProtoReflect ¶
func (x *SubscriptionRequest) ProtoReflect() protoreflect.Message
func (*SubscriptionRequest) Reset ¶
func (x *SubscriptionRequest) Reset()
func (*SubscriptionRequest) String ¶
func (x *SubscriptionRequest) String() string
type UnimplementedStatisticsServer ¶
type UnimplementedStatisticsServer struct { }
UnimplementedStatisticsServer must be embedded to have forward compatible implementations.
func (UnimplementedStatisticsServer) ListStatistics ¶
func (UnimplementedStatisticsServer) ListStatistics(*SubscriptionRequest, Statistics_ListStatisticsServer) error
type UnsafeStatisticsServer ¶
type UnsafeStatisticsServer interface {
// contains filtered or unexported methods
}
UnsafeStatisticsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to StatisticsServer will result in compilation errors.