Documentation ¶
Index ¶
- Variables
- func RegisterEdgeServiceServer(s grpc.ServiceRegistrar, srv EdgeServiceServer)
- type ConfigurationRequest
- func (*ConfigurationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ConfigurationRequest) GetDeviceId() string
- func (*ConfigurationRequest) ProtoMessage()
- func (x *ConfigurationRequest) ProtoReflect() protoreflect.Message
- func (x *ConfigurationRequest) Reset()
- func (x *ConfigurationRequest) String() string
- type ConfigurationResponse
- func (*ConfigurationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ConfigurationResponse) GetConfiguration() *common.Configuration
- func (x *ConfigurationResponse) GetHash() string
- func (x *ConfigurationResponse) GetWorkloads() []*Workload
- func (*ConfigurationResponse) ProtoMessage()
- func (x *ConfigurationResponse) ProtoReflect() protoreflect.Message
- func (x *ConfigurationResponse) Reset()
- func (x *ConfigurationResponse) String() string
- type EdgeServiceClient
- type EdgeServiceServer
- type EnrolRequest
- type EnrolResponse
- type EnrolmentStatus
- func (EnrolmentStatus) Descriptor() protoreflect.EnumDescriptor
- func (x EnrolmentStatus) Enum() *EnrolmentStatus
- func (EnrolmentStatus) EnumDescriptor() ([]byte, []int)deprecated
- func (x EnrolmentStatus) Number() protoreflect.EnumNumber
- func (x EnrolmentStatus) String() string
- func (EnrolmentStatus) Type() protoreflect.EnumType
- type RegistrationRequest
- func (*RegistrationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RegistrationRequest) GetCertificateRequest() string
- func (x *RegistrationRequest) GetDeviceId() string
- func (*RegistrationRequest) ProtoMessage()
- func (x *RegistrationRequest) ProtoReflect() protoreflect.Message
- func (x *RegistrationRequest) Reset()
- func (x *RegistrationRequest) String() string
- type RegistrationResponse
- func (*RegistrationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *RegistrationResponse) GetCertificate() string
- func (*RegistrationResponse) ProtoMessage()
- func (x *RegistrationResponse) ProtoReflect() protoreflect.Message
- func (x *RegistrationResponse) Reset()
- func (x *RegistrationResponse) String() string
- type UnimplementedEdgeServiceServer
- func (UnimplementedEdgeServiceServer) Enrol(context.Context, *EnrolRequest) (*EnrolResponse, error)
- func (UnimplementedEdgeServiceServer) GetConfiguration(context.Context, *ConfigurationRequest) (*ConfigurationResponse, error)
- func (UnimplementedEdgeServiceServer) Heartbeat(context.Context, *common.HeartbeatInfo) (*common.Empty, error)
- func (UnimplementedEdgeServiceServer) Register(context.Context, *RegistrationRequest) (*RegistrationResponse, error)
- type UnsafeEdgeServiceServer
- type Workload
- func (*Workload) Descriptor() ([]byte, []int)deprecated
- func (x *Workload) GetData() []byte
- func (x *Workload) GetHash() string
- func (x *Workload) GetId() string
- func (x *Workload) GetKind() WorkloadKind
- func (x *Workload) GetName() string
- func (*Workload) ProtoMessage()
- func (x *Workload) ProtoReflect() protoreflect.Message
- func (x *Workload) Reset()
- func (x *Workload) String() string
- type WorkloadKind
- func (WorkloadKind) Descriptor() protoreflect.EnumDescriptor
- func (x WorkloadKind) Enum() *WorkloadKind
- func (WorkloadKind) EnumDescriptor() ([]byte, []int)deprecated
- func (x WorkloadKind) Number() protoreflect.EnumNumber
- func (x WorkloadKind) String() string
- func (WorkloadKind) Type() protoreflect.EnumType
Constants ¶
This section is empty.
Variables ¶
var ( EnrolmentStatus_name = map[int32]string{ 0: "PENDING", 1: "ENROLED", 2: "REFUSED", 3: "NOT_ENROLED", } EnrolmentStatus_value = map[string]int32{ "PENDING": 0, "ENROLED": 1, "REFUSED": 2, "NOT_ENROLED": 3, } )
Enum value maps for EnrolmentStatus.
var ( WorkloadKind_name = map[int32]string{ 0: "POD", 1: "QUADLET", 2: "UNSPECIFIED", } WorkloadKind_value = map[string]int32{ "POD": 0, "QUADLET": 1, "UNSPECIFIED": 2, } )
Enum value maps for WorkloadKind.
var EdgeService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "EdgeService", HandlerType: (*EdgeServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Enrol", Handler: _EdgeService_Enrol_Handler, }, { MethodName: "Register", Handler: _EdgeService_Register_Handler, }, { MethodName: "GetConfiguration", Handler: _EdgeService_GetConfiguration_Handler, }, { MethodName: "Heartbeat", Handler: _EdgeService_Heartbeat_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "edge.proto", }
EdgeService_ServiceDesc is the grpc.ServiceDesc for EdgeService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_edge_proto protoreflect.FileDescriptor
Functions ¶
func RegisterEdgeServiceServer ¶
func RegisterEdgeServiceServer(s grpc.ServiceRegistrar, srv EdgeServiceServer)
Types ¶
type ConfigurationRequest ¶
type ConfigurationRequest struct { DeviceId string `protobuf:"bytes,1,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"` // contains filtered or unexported fields }
func (*ConfigurationRequest) Descriptor
deprecated
func (*ConfigurationRequest) Descriptor() ([]byte, []int)
Deprecated: Use ConfigurationRequest.ProtoReflect.Descriptor instead.
func (*ConfigurationRequest) GetDeviceId ¶
func (x *ConfigurationRequest) GetDeviceId() string
func (*ConfigurationRequest) ProtoMessage ¶
func (*ConfigurationRequest) ProtoMessage()
func (*ConfigurationRequest) ProtoReflect ¶
func (x *ConfigurationRequest) ProtoReflect() protoreflect.Message
func (*ConfigurationRequest) Reset ¶
func (x *ConfigurationRequest) Reset()
func (*ConfigurationRequest) String ¶
func (x *ConfigurationRequest) String() string
type ConfigurationResponse ¶
type ConfigurationResponse struct { // sha256 sum of the configuration Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` Configuration *common.Configuration `protobuf:"bytes,2,opt,name=configuration,proto3" json:"configuration,omitempty"` Workloads []*Workload `protobuf:"bytes,3,rep,name=workloads,proto3" json:"workloads,omitempty"` // contains filtered or unexported fields }
func (*ConfigurationResponse) Descriptor
deprecated
func (*ConfigurationResponse) Descriptor() ([]byte, []int)
Deprecated: Use ConfigurationResponse.ProtoReflect.Descriptor instead.
func (*ConfigurationResponse) GetConfiguration ¶
func (x *ConfigurationResponse) GetConfiguration() *common.Configuration
func (*ConfigurationResponse) GetHash ¶
func (x *ConfigurationResponse) GetHash() string
func (*ConfigurationResponse) GetWorkloads ¶
func (x *ConfigurationResponse) GetWorkloads() []*Workload
func (*ConfigurationResponse) ProtoMessage ¶
func (*ConfigurationResponse) ProtoMessage()
func (*ConfigurationResponse) ProtoReflect ¶
func (x *ConfigurationResponse) ProtoReflect() protoreflect.Message
func (*ConfigurationResponse) Reset ¶
func (x *ConfigurationResponse) Reset()
func (*ConfigurationResponse) String ¶
func (x *ConfigurationResponse) String() string
type EdgeServiceClient ¶
type EdgeServiceClient interface { // Enrol is called by a worker to send the request to enrol the fleet. Enrol(ctx context.Context, in *EnrolRequest, opts ...grpc.CallOption) (*EnrolResponse, error) // Register is called by a worker to indicate it is ready and capable of // handling the specified type of work. Register(ctx context.Context, in *RegistrationRequest, opts ...grpc.CallOption) (*RegistrationResponse, error) // GetConfig can be called by a worker to get the current configuration // state of the dispatcher service. GetConfiguration(ctx context.Context, in *ConfigurationRequest, opts ...grpc.CallOption) (*ConfigurationResponse, error) // Heartbeat is called by the worker to send the heartbeat information. Heartbeat(ctx context.Context, in *common.HeartbeatInfo, opts ...grpc.CallOption) (*common.Empty, error) }
EdgeServiceClient is the client API for EdgeService 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 NewEdgeServiceClient ¶
func NewEdgeServiceClient(cc grpc.ClientConnInterface) EdgeServiceClient
type EdgeServiceServer ¶
type EdgeServiceServer interface { // Enrol is called by a worker to send the request to enrol the fleet. Enrol(context.Context, *EnrolRequest) (*EnrolResponse, error) // Register is called by a worker to indicate it is ready and capable of // handling the specified type of work. Register(context.Context, *RegistrationRequest) (*RegistrationResponse, error) // GetConfig can be called by a worker to get the current configuration // state of the dispatcher service. GetConfiguration(context.Context, *ConfigurationRequest) (*ConfigurationResponse, error) // Heartbeat is called by the worker to send the heartbeat information. Heartbeat(context.Context, *common.HeartbeatInfo) (*common.Empty, error) // contains filtered or unexported methods }
EdgeServiceServer is the server API for EdgeService service. All implementations must embed UnimplementedEdgeServiceServer for forward compatibility
type EnrolRequest ¶
type EnrolRequest struct { // device id DeviceId string `protobuf:"bytes,1,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"` // contains filtered or unexported fields }
A EnrolRequest message contains information necessary for a client to request enrolment.
func (*EnrolRequest) Descriptor
deprecated
func (*EnrolRequest) Descriptor() ([]byte, []int)
Deprecated: Use EnrolRequest.ProtoReflect.Descriptor instead.
func (*EnrolRequest) GetDeviceId ¶
func (x *EnrolRequest) GetDeviceId() string
func (*EnrolRequest) ProtoMessage ¶
func (*EnrolRequest) ProtoMessage()
func (*EnrolRequest) ProtoReflect ¶
func (x *EnrolRequest) ProtoReflect() protoreflect.Message
func (*EnrolRequest) Reset ¶
func (x *EnrolRequest) Reset()
func (*EnrolRequest) String ¶
func (x *EnrolRequest) String() string
type EnrolResponse ¶
type EnrolResponse struct { EnrolmentStatus EnrolmentStatus `` /* 128-byte string literal not displayed */ // contains filtered or unexported fields }
func (*EnrolResponse) Descriptor
deprecated
func (*EnrolResponse) Descriptor() ([]byte, []int)
Deprecated: Use EnrolResponse.ProtoReflect.Descriptor instead.
func (*EnrolResponse) GetEnrolmentStatus ¶
func (x *EnrolResponse) GetEnrolmentStatus() EnrolmentStatus
func (*EnrolResponse) ProtoMessage ¶
func (*EnrolResponse) ProtoMessage()
func (*EnrolResponse) ProtoReflect ¶
func (x *EnrolResponse) ProtoReflect() protoreflect.Message
func (*EnrolResponse) Reset ¶
func (x *EnrolResponse) Reset()
func (*EnrolResponse) String ¶
func (x *EnrolResponse) String() string
type EnrolmentStatus ¶
type EnrolmentStatus int32
const ( EnrolmentStatus_PENDING EnrolmentStatus = 0 EnrolmentStatus_ENROLED EnrolmentStatus = 1 EnrolmentStatus_REFUSED EnrolmentStatus = 2 EnrolmentStatus_NOT_ENROLED EnrolmentStatus = 3 )
func (EnrolmentStatus) Descriptor ¶
func (EnrolmentStatus) Descriptor() protoreflect.EnumDescriptor
func (EnrolmentStatus) Enum ¶
func (x EnrolmentStatus) Enum() *EnrolmentStatus
func (EnrolmentStatus) EnumDescriptor
deprecated
func (EnrolmentStatus) EnumDescriptor() ([]byte, []int)
Deprecated: Use EnrolmentStatus.Descriptor instead.
func (EnrolmentStatus) Number ¶
func (x EnrolmentStatus) Number() protoreflect.EnumNumber
func (EnrolmentStatus) String ¶
func (x EnrolmentStatus) String() string
func (EnrolmentStatus) Type ¶
func (EnrolmentStatus) Type() protoreflect.EnumType
type RegistrationRequest ¶
type RegistrationRequest struct { // device id DeviceId string `protobuf:"bytes,1,opt,name=device_id,json=deviceId,proto3" json:"device_id,omitempty"` // certificate sign request CertificateRequest string `protobuf:"bytes,2,opt,name=certificate_request,json=certificateRequest,proto3" json:"certificate_request,omitempty"` // contains filtered or unexported fields }
A RegistrationRequest message contains information necessary for a client to request registration.
func (*RegistrationRequest) Descriptor
deprecated
func (*RegistrationRequest) Descriptor() ([]byte, []int)
Deprecated: Use RegistrationRequest.ProtoReflect.Descriptor instead.
func (*RegistrationRequest) GetCertificateRequest ¶
func (x *RegistrationRequest) GetCertificateRequest() string
func (*RegistrationRequest) GetDeviceId ¶
func (x *RegistrationRequest) GetDeviceId() string
func (*RegistrationRequest) ProtoMessage ¶
func (*RegistrationRequest) ProtoMessage()
func (*RegistrationRequest) ProtoReflect ¶
func (x *RegistrationRequest) ProtoReflect() protoreflect.Message
func (*RegistrationRequest) Reset ¶
func (x *RegistrationRequest) Reset()
func (*RegistrationRequest) String ¶
func (x *RegistrationRequest) String() string
type RegistrationResponse ¶
type RegistrationResponse struct { Certificate string `protobuf:"bytes,1,opt,name=certificate,proto3" json:"certificate,omitempty"` // contains filtered or unexported fields }
A RegistrationResponse message contains the result of a registration request.
func (*RegistrationResponse) Descriptor
deprecated
func (*RegistrationResponse) Descriptor() ([]byte, []int)
Deprecated: Use RegistrationResponse.ProtoReflect.Descriptor instead.
func (*RegistrationResponse) GetCertificate ¶
func (x *RegistrationResponse) GetCertificate() string
func (*RegistrationResponse) ProtoMessage ¶
func (*RegistrationResponse) ProtoMessage()
func (*RegistrationResponse) ProtoReflect ¶
func (x *RegistrationResponse) ProtoReflect() protoreflect.Message
func (*RegistrationResponse) Reset ¶
func (x *RegistrationResponse) Reset()
func (*RegistrationResponse) String ¶
func (x *RegistrationResponse) String() string
type UnimplementedEdgeServiceServer ¶
type UnimplementedEdgeServiceServer struct { }
UnimplementedEdgeServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedEdgeServiceServer) Enrol ¶
func (UnimplementedEdgeServiceServer) Enrol(context.Context, *EnrolRequest) (*EnrolResponse, error)
func (UnimplementedEdgeServiceServer) GetConfiguration ¶
func (UnimplementedEdgeServiceServer) GetConfiguration(context.Context, *ConfigurationRequest) (*ConfigurationResponse, error)
func (UnimplementedEdgeServiceServer) Heartbeat ¶
func (UnimplementedEdgeServiceServer) Heartbeat(context.Context, *common.HeartbeatInfo) (*common.Empty, error)
func (UnimplementedEdgeServiceServer) Register ¶
func (UnimplementedEdgeServiceServer) Register(context.Context, *RegistrationRequest) (*RegistrationResponse, error)
type UnsafeEdgeServiceServer ¶
type UnsafeEdgeServiceServer interface {
// contains filtered or unexported methods
}
UnsafeEdgeServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EdgeServiceServer will result in compilation errors.
type Workload ¶
type Workload struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Hash string `protobuf:"bytes,3,opt,name=hash,proto3" json:"hash,omitempty"` Kind WorkloadKind `protobuf:"varint,4,opt,name=kind,proto3,enum=WorkloadKind" json:"kind,omitempty"` Data []byte `protobuf:"bytes,7,opt,name=data,proto3" json:"data,omitempty"` // contains filtered or unexported fields }
func (*Workload) Descriptor
deprecated
func (*Workload) GetKind ¶
func (x *Workload) GetKind() WorkloadKind
func (*Workload) ProtoMessage ¶
func (*Workload) ProtoMessage()
func (*Workload) ProtoReflect ¶
func (x *Workload) ProtoReflect() protoreflect.Message
type WorkloadKind ¶
type WorkloadKind int32
const ( WorkloadKind_POD WorkloadKind = 0 WorkloadKind_QUADLET WorkloadKind = 1 WorkloadKind_UNSPECIFIED WorkloadKind = 2 )
func (WorkloadKind) Descriptor ¶
func (WorkloadKind) Descriptor() protoreflect.EnumDescriptor
func (WorkloadKind) Enum ¶
func (x WorkloadKind) Enum() *WorkloadKind
func (WorkloadKind) EnumDescriptor
deprecated
func (WorkloadKind) EnumDescriptor() ([]byte, []int)
Deprecated: Use WorkloadKind.Descriptor instead.
func (WorkloadKind) Number ¶
func (x WorkloadKind) Number() protoreflect.EnumNumber
func (WorkloadKind) String ¶
func (x WorkloadKind) String() string
func (WorkloadKind) Type ¶
func (WorkloadKind) Type() protoreflect.EnumType