agent

package
v0.0.0-...-5808d2a Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Agent_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "agent.Agent",
	HandlerType: (*AgentServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "AddTask",
			Handler:    _Agent_AddTask_Handler,
		},
		{
			MethodName: "ModifyTask",
			Handler:    _Agent_ModifyTask_Handler,
		},
		{
			MethodName: "ApplyCertificate",
			Handler:    _Agent_ApplyCertificate_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "agent/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)

View Source
var File_agent_agent_proto protoreflect.FileDescriptor

Functions

func RegisterAgentServer

func RegisterAgentServer(s grpc.ServiceRegistrar, srv AgentServer)

Types

type AgentClient

type AgentClient interface {
	AddTask(ctx context.Context, in *common.TaskInfo, opts ...grpc.CallOption) (*common.Empty, error)
	ModifyTask(ctx context.Context, in *common.TaskInfo, opts ...grpc.CallOption) (*common.Empty, error)
	ApplyCertificate(ctx context.Context, in *ApplyCertificateReq, opts ...grpc.CallOption) (*common.Certificate, error)
}

AgentClient is the client API for Agent service.

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

func NewAgentClient

func NewAgentClient(cc grpc.ClientConnInterface) AgentClient

type AgentServer

type AgentServer interface {
	AddTask(context.Context, *common.TaskInfo) (*common.Empty, error)
	ModifyTask(context.Context, *common.TaskInfo) (*common.Empty, error)
	ApplyCertificate(context.Context, *ApplyCertificateReq) (*common.Certificate, error)
}

AgentServer is the server API for Agent service. All implementations must embed UnimplementedAgentServer for forward compatibility

type ApplyCertificateReq

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

func (*ApplyCertificateReq) Descriptor deprecated

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

Deprecated: Use ApplyCertificateReq.ProtoReflect.Descriptor instead.

func (*ApplyCertificateReq) GetDomain

func (x *ApplyCertificateReq) GetDomain() string

func (*ApplyCertificateReq) ProtoMessage

func (*ApplyCertificateReq) ProtoMessage()

func (*ApplyCertificateReq) ProtoReflect

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

func (*ApplyCertificateReq) Reset

func (x *ApplyCertificateReq) Reset()

func (*ApplyCertificateReq) String

func (x *ApplyCertificateReq) String() string

type UnimplementedAgentServer

type UnimplementedAgentServer struct {
}

UnimplementedAgentServer must be embedded to have forward compatible implementations.

func (UnimplementedAgentServer) AddTask

func (UnimplementedAgentServer) ApplyCertificate

func (UnimplementedAgentServer) ModifyTask

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.

Jump to

Keyboard shortcuts

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