proto

package module
v0.0.0-...-9b4d8c9 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2026 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AgentService_Connect_FullMethodName = "/deft.AgentService/Connect"
)

Variables

View Source
var AgentService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "deft.AgentService",
	HandlerType: (*AgentServiceServer)(nil),
	Methods:     []grpc.MethodDesc{},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "Connect",
			Handler:       _AgentService_Connect_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "proto/agent.proto",
}

AgentService_ServiceDesc is the grpc.ServiceDesc for AgentService 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_proto_agent_proto protoreflect.FileDescriptor

Functions

func RegisterAgentServiceServer

func RegisterAgentServiceServer(s grpc.ServiceRegistrar, srv AgentServiceServer)

Types

type AgentMessage

type AgentMessage struct {
	NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"`
	// Types that are valid to be assigned to Content:
	//
	//	*AgentMessage_Heartbeat
	//	*AgentMessage_Result
	//	*AgentMessage_Stats
	Content isAgentMessage_Content `protobuf_oneof:"content"`
	// contains filtered or unexported fields
}

func (*AgentMessage) Descriptor deprecated

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

Deprecated: Use AgentMessage.ProtoReflect.Descriptor instead.

func (*AgentMessage) GetContent

func (x *AgentMessage) GetContent() isAgentMessage_Content

func (*AgentMessage) GetHeartbeat

func (x *AgentMessage) GetHeartbeat() *Heartbeat

func (*AgentMessage) GetNodeId

func (x *AgentMessage) GetNodeId() string

func (*AgentMessage) GetResult

func (x *AgentMessage) GetResult() *CommandResult

func (*AgentMessage) GetStats

func (x *AgentMessage) GetStats() *StatsUpdate

func (*AgentMessage) ProtoMessage

func (*AgentMessage) ProtoMessage()

func (*AgentMessage) ProtoReflect

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

func (*AgentMessage) Reset

func (x *AgentMessage) Reset()

func (*AgentMessage) String

func (x *AgentMessage) String() string

type AgentMessage_Heartbeat

type AgentMessage_Heartbeat struct {
	Heartbeat *Heartbeat `protobuf:"bytes,2,opt,name=heartbeat,proto3,oneof"`
}

type AgentMessage_Result

type AgentMessage_Result struct {
	Result *CommandResult `protobuf:"bytes,3,opt,name=result,proto3,oneof"`
}

type AgentMessage_Stats

type AgentMessage_Stats struct {
	Stats *StatsUpdate `protobuf:"bytes,4,opt,name=stats,proto3,oneof"`
}

type AgentServiceClient

type AgentServiceClient interface {
	Connect(ctx context.Context, opts ...grpc.CallOption) (grpc.BidiStreamingClient[AgentMessage, PanelCommand], error)
}

AgentServiceClient is the client API for AgentService 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.

type AgentServiceServer

type AgentServiceServer interface {
	Connect(grpc.BidiStreamingServer[AgentMessage, PanelCommand]) error
	// contains filtered or unexported methods
}

AgentServiceServer is the server API for AgentService service. All implementations must embed UnimplementedAgentServiceServer for forward compatibility.

type AgentService_ConnectClient

type AgentService_ConnectClient = grpc.BidiStreamingClient[AgentMessage, PanelCommand]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type AgentService_ConnectServer

type AgentService_ConnectServer = grpc.BidiStreamingServer[AgentMessage, PanelCommand]

This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.

type CommandResult

type CommandResult struct {
	CommandId string `protobuf:"bytes,1,opt,name=command_id,json=commandId,proto3" json:"command_id,omitempty"`
	Success   bool   `protobuf:"varint,2,opt,name=success,proto3" json:"success,omitempty"`
	Message   string `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*CommandResult) Descriptor deprecated

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

Deprecated: Use CommandResult.ProtoReflect.Descriptor instead.

func (*CommandResult) GetCommandId

func (x *CommandResult) GetCommandId() string

func (*CommandResult) GetMessage

func (x *CommandResult) GetMessage() string

func (*CommandResult) GetSuccess

func (x *CommandResult) GetSuccess() bool

func (*CommandResult) ProtoMessage

func (*CommandResult) ProtoMessage()

func (*CommandResult) ProtoReflect

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

func (*CommandResult) Reset

func (x *CommandResult) Reset()

func (*CommandResult) String

func (x *CommandResult) String() string

type CreateContainer

type CreateContainer struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Image string `protobuf:"bytes,2,opt,name=image,proto3" json:"image,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateContainer) Descriptor deprecated

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

Deprecated: Use CreateContainer.ProtoReflect.Descriptor instead.

func (*CreateContainer) GetImage

func (x *CreateContainer) GetImage() string

func (*CreateContainer) GetName

func (x *CreateContainer) GetName() string

func (*CreateContainer) ProtoMessage

func (*CreateContainer) ProtoMessage()

func (*CreateContainer) ProtoReflect

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

func (*CreateContainer) Reset

func (x *CreateContainer) Reset()

func (*CreateContainer) String

func (x *CreateContainer) String() string

type Heartbeat

type Heartbeat struct {
	Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*Heartbeat) Descriptor deprecated

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

Deprecated: Use Heartbeat.ProtoReflect.Descriptor instead.

func (*Heartbeat) GetTimestamp

func (x *Heartbeat) GetTimestamp() int64

func (*Heartbeat) ProtoMessage

func (*Heartbeat) ProtoMessage()

func (*Heartbeat) ProtoReflect

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

func (*Heartbeat) Reset

func (x *Heartbeat) Reset()

func (*Heartbeat) String

func (x *Heartbeat) String() string

type PanelCommand

type PanelCommand struct {
	CommandId string `protobuf:"bytes,1,opt,name=command_id,json=commandId,proto3" json:"command_id,omitempty"`
	// Types that are valid to be assigned to Action:
	//
	//	*PanelCommand_Create
	//	*PanelCommand_Start
	//	*PanelCommand_Stop
	//	*PanelCommand_Remove
	Action isPanelCommand_Action `protobuf_oneof:"action"`
	// contains filtered or unexported fields
}

func (*PanelCommand) Descriptor deprecated

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

Deprecated: Use PanelCommand.ProtoReflect.Descriptor instead.

func (*PanelCommand) GetAction

func (x *PanelCommand) GetAction() isPanelCommand_Action

func (*PanelCommand) GetCommandId

func (x *PanelCommand) GetCommandId() string

func (*PanelCommand) GetCreate

func (x *PanelCommand) GetCreate() *CreateContainer

func (*PanelCommand) GetRemove

func (x *PanelCommand) GetRemove() *RemoveContainer

func (*PanelCommand) GetStart

func (x *PanelCommand) GetStart() *StartContainer

func (*PanelCommand) GetStop

func (x *PanelCommand) GetStop() *StopContainer

func (*PanelCommand) ProtoMessage

func (*PanelCommand) ProtoMessage()

func (*PanelCommand) ProtoReflect

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

func (*PanelCommand) Reset

func (x *PanelCommand) Reset()

func (*PanelCommand) String

func (x *PanelCommand) String() string

type PanelCommand_Create

type PanelCommand_Create struct {
	Create *CreateContainer `protobuf:"bytes,2,opt,name=create,proto3,oneof"`
}

type PanelCommand_Remove

type PanelCommand_Remove struct {
	Remove *RemoveContainer `protobuf:"bytes,5,opt,name=remove,proto3,oneof"`
}

type PanelCommand_Start

type PanelCommand_Start struct {
	Start *StartContainer `protobuf:"bytes,3,opt,name=start,proto3,oneof"`
}

type PanelCommand_Stop

type PanelCommand_Stop struct {
	Stop *StopContainer `protobuf:"bytes,4,opt,name=stop,proto3,oneof"`
}

type RemoveContainer

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

func (*RemoveContainer) Descriptor deprecated

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

Deprecated: Use RemoveContainer.ProtoReflect.Descriptor instead.

func (*RemoveContainer) GetId

func (x *RemoveContainer) GetId() string

func (*RemoveContainer) ProtoMessage

func (*RemoveContainer) ProtoMessage()

func (*RemoveContainer) ProtoReflect

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

func (*RemoveContainer) Reset

func (x *RemoveContainer) Reset()

func (*RemoveContainer) String

func (x *RemoveContainer) String() string

type StartContainer

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

func (*StartContainer) Descriptor deprecated

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

Deprecated: Use StartContainer.ProtoReflect.Descriptor instead.

func (*StartContainer) GetId

func (x *StartContainer) GetId() string

func (*StartContainer) ProtoMessage

func (*StartContainer) ProtoMessage()

func (*StartContainer) ProtoReflect

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

func (*StartContainer) Reset

func (x *StartContainer) Reset()

func (*StartContainer) String

func (x *StartContainer) String() string

type StatsUpdate

type StatsUpdate struct {
	ContainerId string  `protobuf:"bytes,1,opt,name=container_id,json=containerId,proto3" json:"container_id,omitempty"`
	CpuPercent  float64 `protobuf:"fixed64,2,opt,name=cpu_percent,json=cpuPercent,proto3" json:"cpu_percent,omitempty"`
	MemoryBytes uint64  `protobuf:"varint,3,opt,name=memory_bytes,json=memoryBytes,proto3" json:"memory_bytes,omitempty"`
	// contains filtered or unexported fields
}

func (*StatsUpdate) Descriptor deprecated

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

Deprecated: Use StatsUpdate.ProtoReflect.Descriptor instead.

func (*StatsUpdate) GetContainerId

func (x *StatsUpdate) GetContainerId() string

func (*StatsUpdate) GetCpuPercent

func (x *StatsUpdate) GetCpuPercent() float64

func (*StatsUpdate) GetMemoryBytes

func (x *StatsUpdate) GetMemoryBytes() uint64

func (*StatsUpdate) ProtoMessage

func (*StatsUpdate) ProtoMessage()

func (*StatsUpdate) ProtoReflect

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

func (*StatsUpdate) Reset

func (x *StatsUpdate) Reset()

func (*StatsUpdate) String

func (x *StatsUpdate) String() string

type StopContainer

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

func (*StopContainer) Descriptor deprecated

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

Deprecated: Use StopContainer.ProtoReflect.Descriptor instead.

func (*StopContainer) GetId

func (x *StopContainer) GetId() string

func (*StopContainer) ProtoMessage

func (*StopContainer) ProtoMessage()

func (*StopContainer) ProtoReflect

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

func (*StopContainer) Reset

func (x *StopContainer) Reset()

func (*StopContainer) String

func (x *StopContainer) String() string

type UnimplementedAgentServiceServer

type UnimplementedAgentServiceServer struct{}

UnimplementedAgentServiceServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

func (UnimplementedAgentServiceServer) Connect

type UnsafeAgentServiceServer

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

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

Jump to

Keyboard shortcuts

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