Documentation
¶
Index ¶
- Variables
- func RegisterAgentServer(s grpc.ServiceRegistrar, srv AgentServer)
- type AgentClient
- type AgentServer
- type CPUPerf
- func (*CPUPerf) Descriptor() ([]byte, []int)deprecated
- func (x *CPUPerf) GetId() string
- func (x *CPUPerf) GetIdle() int32
- func (x *CPUPerf) GetIoWait() int32
- func (x *CPUPerf) GetIrq() int32
- func (x *CPUPerf) GetSystem() int32
- func (x *CPUPerf) GetUser() int32
- func (*CPUPerf) ProtoMessage()
- func (x *CPUPerf) ProtoReflect() protoreflect.Message
- func (x *CPUPerf) Reset()
- func (x *CPUPerf) String() string
- type CPUPerfs
- func (*CPUPerfs) Descriptor() ([]byte, []int)deprecated
- func (x *CPUPerfs) GetCpu() []*CPUPerf
- func (x *CPUPerfs) GetResolutionSecs() int32
- func (x *CPUPerfs) GetUnixTimeNano() int64
- func (x *CPUPerfs) MarshalJSON() ([]byte, error)
- func (*CPUPerfs) ProtoMessage()
- func (x *CPUPerfs) ProtoReflect() protoreflect.Message
- func (x *CPUPerfs) Reset()
- func (x *CPUPerfs) String() string
- func (x *CPUPerfs) UnmarshalJSON(b []byte) error
- type InstallReq
- func (*InstallReq) Descriptor() ([]byte, []int)deprecated
- func (x *InstallReq) GetArgs() []string
- func (x *InstallReq) GetBinary() string
- func (x *InstallReq) GetName() string
- func (x *InstallReq) GetPackage() []byte
- func (*InstallReq) ProtoMessage()
- func (x *InstallReq) ProtoReflect() protoreflect.Message
- func (x *InstallReq) Reset()
- func (x *InstallReq) String() string
- func (i *InstallReq) Validate() error
- type InstallResp
- type MemPerf
- func (*MemPerf) Descriptor() ([]byte, []int)deprecated
- func (x *MemPerf) GetAvail() int32
- func (x *MemPerf) GetFree() int32
- func (x *MemPerf) GetResolutionSecs() int32
- func (x *MemPerf) GetTotal() int32
- func (x *MemPerf) GetUnixTimeNano() int64
- func (x *MemPerf) MarshalJSON() ([]byte, error)
- func (*MemPerf) ProtoMessage()
- func (x *MemPerf) ProtoReflect() protoreflect.Message
- func (x *MemPerf) Reset()
- func (x *MemPerf) String() string
- func (x *MemPerf) UnmarshalJSON(b []byte) error
- type RemoveReq
- type RemoveResp
- type UnimplementedAgentServer
- type UnsafeAgentServer
Constants ¶
This section is empty.
Variables ¶
var Agent_ServiceDesc = grpc.ServiceDesc{ ServiceName: "system.agent.Agent", HandlerType: (*AgentServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Install", Handler: _Agent_Install_Handler, }, { MethodName: "Remove", Handler: _Agent_Remove_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "agent.proto", }
Agent_ServiceDesc is the grpc.ServiceDesc for Agent service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_agent_proto protoreflect.FileDescriptor
Functions ¶
func RegisterAgentServer ¶
func RegisterAgentServer(s grpc.ServiceRegistrar, srv AgentServer)
Types ¶
type AgentClient ¶
type AgentClient interface { Install(ctx context.Context, in *InstallReq, opts ...grpc.CallOption) (*InstallResp, error) Remove(ctx context.Context, in *RemoveReq, opts ...grpc.CallOption) (*RemoveResp, error) }
AgentClient is the client API for Agent 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 NewAgentClient ¶
func NewAgentClient(cc grpc.ClientConnInterface) AgentClient
type AgentServer ¶
type AgentServer interface { Install(context.Context, *InstallReq) (*InstallResp, error) Remove(context.Context, *RemoveReq) (*RemoveResp, error) // contains filtered or unexported methods }
AgentServer is the server API for Agent service. All implementations must embed UnimplementedAgentServer for forward compatibility
type CPUPerf ¶
type CPUPerf struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` User int32 `protobuf:"varint,2,opt,name=user,proto3" json:"user,omitempty"` System int32 `protobuf:"varint,3,opt,name=system,proto3" json:"system,omitempty"` Idle int32 `protobuf:"varint,4,opt,name=idle,proto3" json:"idle,omitempty"` IoWait int32 `protobuf:"varint,5,opt,name=io_wait,json=ioWait,proto3" json:"io_wait,omitempty"` Irq int32 `protobuf:"varint,6,opt,name=irq,proto3" json:"irq,omitempty"` // contains filtered or unexported fields }
func (*CPUPerf) Descriptor
deprecated
func (*CPUPerf) ProtoMessage ¶
func (*CPUPerf) ProtoMessage()
func (*CPUPerf) ProtoReflect ¶
func (x *CPUPerf) ProtoReflect() protoreflect.Message
type CPUPerfs ¶
type CPUPerfs struct { ResolutionSecs int32 `protobuf:"varint,1,opt,name=resolutionSecs,proto3" json:"resolutionSecs,omitempty"` UnixTimeNano int64 `protobuf:"varint,2,opt,name=unix_time_nano,json=unixTimeNano,proto3" json:"unix_time_nano,omitempty"` Cpu []*CPUPerf `protobuf:"bytes,3,rep,name=cpu,proto3" json:"cpu,omitempty"` // contains filtered or unexported fields }
func (*CPUPerfs) Descriptor
deprecated
func (*CPUPerfs) GetResolutionSecs ¶
func (*CPUPerfs) GetUnixTimeNano ¶
func (*CPUPerfs) MarshalJSON ¶
MarshalJSON implement json.Marshaller for CPUPerfs so that we use the protojson.Marshal() instead of the standard marshaller.
func (*CPUPerfs) ProtoMessage ¶
func (*CPUPerfs) ProtoMessage()
func (*CPUPerfs) ProtoReflect ¶
func (x *CPUPerfs) ProtoReflect() protoreflect.Message
func (*CPUPerfs) UnmarshalJSON ¶
UnmarshalJSON implement json.Unmarshaller for CPUPerfs so that we use the protojson.Unmarshal() instead of the standard unmarshaller.
type InstallReq ¶
type InstallReq struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Package []byte `protobuf:"bytes,2,opt,name=package,proto3" json:"package,omitempty"` Binary string `protobuf:"bytes,3,opt,name=binary,proto3" json:"binary,omitempty"` Args []string `protobuf:"bytes,4,rep,name=args,proto3" json:"args,omitempty"` // contains filtered or unexported fields }
func (*InstallReq) Descriptor
deprecated
func (*InstallReq) Descriptor() ([]byte, []int)
Deprecated: Use InstallReq.ProtoReflect.Descriptor instead.
func (*InstallReq) GetArgs ¶
func (x *InstallReq) GetArgs() []string
func (*InstallReq) GetBinary ¶
func (x *InstallReq) GetBinary() string
func (*InstallReq) GetName ¶
func (x *InstallReq) GetName() string
func (*InstallReq) GetPackage ¶
func (x *InstallReq) GetPackage() []byte
func (*InstallReq) ProtoMessage ¶
func (*InstallReq) ProtoMessage()
func (*InstallReq) ProtoReflect ¶
func (x *InstallReq) ProtoReflect() protoreflect.Message
func (*InstallReq) Reset ¶
func (x *InstallReq) Reset()
func (*InstallReq) String ¶
func (x *InstallReq) String() string
func (*InstallReq) Validate ¶
func (i *InstallReq) Validate() error
Validate is used to validate an InstallReq.
type InstallResp ¶
type InstallResp struct {
// contains filtered or unexported fields
}
func (*InstallResp) Descriptor
deprecated
func (*InstallResp) Descriptor() ([]byte, []int)
Deprecated: Use InstallResp.ProtoReflect.Descriptor instead.
func (*InstallResp) ProtoMessage ¶
func (*InstallResp) ProtoMessage()
func (*InstallResp) ProtoReflect ¶
func (x *InstallResp) ProtoReflect() protoreflect.Message
func (*InstallResp) Reset ¶
func (x *InstallResp) Reset()
func (*InstallResp) String ¶
func (x *InstallResp) String() string
type MemPerf ¶
type MemPerf struct { ResolutionSecs int32 `protobuf:"varint,1,opt,name=resolutionSecs,proto3" json:"resolutionSecs,omitempty"` UnixTimeNano int64 `protobuf:"varint,2,opt,name=unix_time_nano,json=unixTimeNano,proto3" json:"unix_time_nano,omitempty"` Total int32 `protobuf:"varint,3,opt,name=total,proto3" json:"total,omitempty"` Free int32 `protobuf:"varint,4,opt,name=free,proto3" json:"free,omitempty"` Avail int32 `protobuf:"varint,5,opt,name=avail,proto3" json:"avail,omitempty"` // contains filtered or unexported fields }
func (*MemPerf) Descriptor
deprecated
func (*MemPerf) GetResolutionSecs ¶
func (*MemPerf) GetUnixTimeNano ¶
func (*MemPerf) MarshalJSON ¶
MarshalJSON implement json.Marshaller for MemPerf so that we use the protojson.Marshal() instead of the standard marshaller.
func (*MemPerf) ProtoMessage ¶
func (*MemPerf) ProtoMessage()
func (*MemPerf) ProtoReflect ¶
func (x *MemPerf) ProtoReflect() protoreflect.Message
func (*MemPerf) UnmarshalJSON ¶
UnmarshalJSON implement json.Unmarshaller for MemPerf so that we use the protojson.Unmarshal() instead of the standard unmarshaller.
type RemoveReq ¶
type RemoveReq struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*RemoveReq) Descriptor
deprecated
func (*RemoveReq) ProtoMessage ¶
func (*RemoveReq) ProtoMessage()
func (*RemoveReq) ProtoReflect ¶
func (x *RemoveReq) ProtoReflect() protoreflect.Message
type RemoveResp ¶
type RemoveResp struct {
// contains filtered or unexported fields
}
func (*RemoveResp) Descriptor
deprecated
func (*RemoveResp) Descriptor() ([]byte, []int)
Deprecated: Use RemoveResp.ProtoReflect.Descriptor instead.
func (*RemoveResp) ProtoMessage ¶
func (*RemoveResp) ProtoMessage()
func (*RemoveResp) ProtoReflect ¶
func (x *RemoveResp) ProtoReflect() protoreflect.Message
func (*RemoveResp) Reset ¶
func (x *RemoveResp) Reset()
func (*RemoveResp) String ¶
func (x *RemoveResp) String() string
type UnimplementedAgentServer ¶
type UnimplementedAgentServer struct { }
UnimplementedAgentServer must be embedded to have forward compatible implementations.
func (UnimplementedAgentServer) Install ¶
func (UnimplementedAgentServer) Install(context.Context, *InstallReq) (*InstallResp, error)
func (UnimplementedAgentServer) Remove ¶
func (UnimplementedAgentServer) Remove(context.Context, *RemoveReq) (*RemoveResp, error)
type UnsafeAgentServer ¶
type UnsafeAgentServer interface {
// contains filtered or unexported methods
}
UnsafeAgentServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to AgentServer will result in compilation errors.