cloud_vmm

package
v0.0.0-...-05f333e Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AgentErrorCode_name = map[int32]string{
	0: "NO_ERROR",
	1: "INVALID_CONFIG",
	2: "SCRIPT_NOT_FOUND",
	3: "SCRIPT_TIMED_OUT",
	4: "UNHANDLED_SCRIPT_ERROR",
}
View Source
var AgentErrorCode_value = map[string]int32{
	"NO_ERROR":               0,
	"INVALID_CONFIG":         1,
	"SCRIPT_NOT_FOUND":       2,
	"SCRIPT_TIMED_OUT":       3,
	"UNHANDLED_SCRIPT_ERROR": 4,
}
View Source
var OperationType_name = map[int32]string{
	0: "NOT_SET",
	1: "PRE_SNAPSHOT",
	2: "POST_SNAPSHOT",
}
View Source
var OperationType_value = map[string]int32{
	"NOT_SET":       0,
	"PRE_SNAPSHOT":  1,
	"POST_SNAPSHOT": 2,
}
View Source
var SupportedFeatures_name = map[int32]string{
	0: "NONE",
	1: "SNAPSHOTS",
}
View Source
var SupportedFeatures_value = map[string]int32{
	"NONE":      0,
	"SNAPSHOTS": 1,
}

Functions

func RegisterSnapshotServiceServer

func RegisterSnapshotServiceServer(s *grpc.Server, srv SnapshotServiceServer)

Types

type AgentErrorCode

type AgentErrorCode int32
const (
	AgentErrorCode_NO_ERROR AgentErrorCode = 0
	// The snapshot config was improper in some way.
	AgentErrorCode_INVALID_CONFIG AgentErrorCode = 1
	// The pre or post snapshot script was not found on disk.
	AgentErrorCode_SCRIPT_NOT_FOUND AgentErrorCode = 2
	// The pre or post snapshot script timed out.
	AgentErrorCode_SCRIPT_TIMED_OUT AgentErrorCode = 3
	// The pre or post snapshot script returned an error, but the "continue on
	// error" flag was not set.
	AgentErrorCode_UNHANDLED_SCRIPT_ERROR AgentErrorCode = 4
)

func (AgentErrorCode) EnumDescriptor

func (AgentErrorCode) EnumDescriptor() ([]byte, []int)

func (AgentErrorCode) String

func (x AgentErrorCode) String() string

type GuestMessage

type GuestMessage struct {
	// Types that are valid to be assigned to Msg:
	//	*GuestMessage_SnapshotRequest
	//	*GuestMessage_ServerInfo
	Msg                  isGuestMessage_Msg `protobuf_oneof:"msg"`
	XXX_NoUnkeyedLiteral struct{}           `json:"-"`
	XXX_unrecognized     []byte             `json:"-"`
	XXX_sizecache        int32              `json:"-"`
}

func (*GuestMessage) Descriptor

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

func (*GuestMessage) GetMsg

func (m *GuestMessage) GetMsg() isGuestMessage_Msg

func (*GuestMessage) GetServerInfo

func (m *GuestMessage) GetServerInfo() *ServerInfo

func (*GuestMessage) GetSnapshotRequest

func (m *GuestMessage) GetSnapshotRequest() *SnapshotRequest

func (*GuestMessage) ProtoMessage

func (*GuestMessage) ProtoMessage()

func (*GuestMessage) Reset

func (m *GuestMessage) Reset()

func (*GuestMessage) String

func (m *GuestMessage) String() string

func (*GuestMessage) XXX_DiscardUnknown

func (m *GuestMessage) XXX_DiscardUnknown()

func (*GuestMessage) XXX_Marshal

func (m *GuestMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GuestMessage) XXX_Merge

func (m *GuestMessage) XXX_Merge(src proto.Message)

func (*GuestMessage) XXX_OneofWrappers

func (*GuestMessage) XXX_OneofWrappers() []interface{}

XXX_OneofWrappers is for the internal use of the proto package.

func (*GuestMessage) XXX_Size

func (m *GuestMessage) XXX_Size() int

func (*GuestMessage) XXX_Unmarshal

func (m *GuestMessage) XXX_Unmarshal(b []byte) error

type GuestMessage_ServerInfo

type GuestMessage_ServerInfo struct {
	ServerInfo *ServerInfo `protobuf:"bytes,2,opt,name=server_info,json=serverInfo,proto3,oneof"`
}

type GuestMessage_SnapshotRequest

type GuestMessage_SnapshotRequest struct {
	SnapshotRequest *SnapshotRequest `protobuf:"bytes,1,opt,name=snapshot_request,json=snapshotRequest,proto3,oneof"`
}

type GuestReady

type GuestReady struct {
	RequestServerInfo    bool     `protobuf:"varint,1,opt,name=request_server_info,json=requestServerInfo,proto3" json:"request_server_info,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*GuestReady) Descriptor

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

func (*GuestReady) GetRequestServerInfo

func (m *GuestReady) GetRequestServerInfo() bool

func (*GuestReady) ProtoMessage

func (*GuestReady) ProtoMessage()

func (*GuestReady) Reset

func (m *GuestReady) Reset()

func (*GuestReady) String

func (m *GuestReady) String() string

func (*GuestReady) XXX_DiscardUnknown

func (m *GuestReady) XXX_DiscardUnknown()

func (*GuestReady) XXX_Marshal

func (m *GuestReady) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GuestReady) XXX_Merge

func (m *GuestReady) XXX_Merge(src proto.Message)

func (*GuestReady) XXX_Size

func (m *GuestReady) XXX_Size() int

func (*GuestReady) XXX_Unmarshal

func (m *GuestReady) XXX_Unmarshal(b []byte) error

type OperationType

type OperationType int32
const (
	OperationType_NOT_SET       OperationType = 0
	OperationType_PRE_SNAPSHOT  OperationType = 1
	OperationType_POST_SNAPSHOT OperationType = 2
)

func (OperationType) EnumDescriptor

func (OperationType) EnumDescriptor() ([]byte, []int)

func (OperationType) String

func (x OperationType) String() string

type ServerAck

type ServerAck struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ServerAck) Descriptor

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

func (*ServerAck) ProtoMessage

func (*ServerAck) ProtoMessage()

func (*ServerAck) Reset

func (m *ServerAck) Reset()

func (*ServerAck) String

func (m *ServerAck) String() string

func (*ServerAck) XXX_DiscardUnknown

func (m *ServerAck) XXX_DiscardUnknown()

func (*ServerAck) XXX_Marshal

func (m *ServerAck) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ServerAck) XXX_Merge

func (m *ServerAck) XXX_Merge(src proto.Message)

func (*ServerAck) XXX_Size

func (m *ServerAck) XXX_Size() int

func (*ServerAck) XXX_Unmarshal

func (m *ServerAck) XXX_Unmarshal(b []byte) error

type ServerInfo

type ServerInfo struct {
	SupportedFeatures    []SupportedFeatures `` /* 153-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}            `json:"-"`
	XXX_unrecognized     []byte              `json:"-"`
	XXX_sizecache        int32               `json:"-"`
}

func (*ServerInfo) Descriptor

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

func (*ServerInfo) GetSupportedFeatures

func (m *ServerInfo) GetSupportedFeatures() []SupportedFeatures

func (*ServerInfo) ProtoMessage

func (*ServerInfo) ProtoMessage()

func (*ServerInfo) Reset

func (m *ServerInfo) Reset()

func (*ServerInfo) String

func (m *ServerInfo) String() string

func (*ServerInfo) XXX_DiscardUnknown

func (m *ServerInfo) XXX_DiscardUnknown()

func (*ServerInfo) XXX_Marshal

func (m *ServerInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ServerInfo) XXX_Merge

func (m *ServerInfo) XXX_Merge(src proto.Message)

func (*ServerInfo) XXX_Size

func (m *ServerInfo) XXX_Size() int

func (*ServerInfo) XXX_Unmarshal

func (m *ServerInfo) XXX_Unmarshal(b []byte) error

type SnapshotRequest

type SnapshotRequest struct {
	// The operation id of the snapshot.
	OperationId int32 `protobuf:"varint,1,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"`
	// A list of comma separated target/lun values, e.g "1/2,3/4".
	DiskList string `protobuf:"bytes,2,opt,name=disk_list,json=diskList,proto3" json:"disk_list,omitempty"`
	// The operation type.
	Type                 OperationType `protobuf:"varint,3,opt,name=type,proto3,enum=cloud.vmm.OperationType" json:"type,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

func (*SnapshotRequest) Descriptor

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

func (*SnapshotRequest) GetDiskList

func (m *SnapshotRequest) GetDiskList() string

func (*SnapshotRequest) GetOperationId

func (m *SnapshotRequest) GetOperationId() int32

func (*SnapshotRequest) GetType

func (m *SnapshotRequest) GetType() OperationType

func (*SnapshotRequest) ProtoMessage

func (*SnapshotRequest) ProtoMessage()

func (*SnapshotRequest) Reset

func (m *SnapshotRequest) Reset()

func (*SnapshotRequest) String

func (m *SnapshotRequest) String() string

func (*SnapshotRequest) XXX_DiscardUnknown

func (m *SnapshotRequest) XXX_DiscardUnknown()

func (*SnapshotRequest) XXX_Marshal

func (m *SnapshotRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SnapshotRequest) XXX_Merge

func (m *SnapshotRequest) XXX_Merge(src proto.Message)

func (*SnapshotRequest) XXX_Size

func (m *SnapshotRequest) XXX_Size() int

func (*SnapshotRequest) XXX_Unmarshal

func (m *SnapshotRequest) XXX_Unmarshal(b []byte) error

type SnapshotResponse

type SnapshotResponse struct {
	// The operation id of the snapshot.
	OperationId int32 `protobuf:"varint,1,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"`
	// The return code of the scripts run by the guest. If this is non-zero, then
	// agent_return_code should be UNHANDLED_SCRIPT_ERROR.
	ScriptsReturnCode int32 `protobuf:"varint,2,opt,name=scripts_return_code,json=scriptsReturnCode,proto3" json:"scripts_return_code,omitempty"`
	// The agent return code.
	AgentReturnCode AgentErrorCode `` /* 139-byte string literal not displayed */
	// The operation type.
	Type                 OperationType `protobuf:"varint,4,opt,name=type,proto3,enum=cloud.vmm.OperationType" json:"type,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

func (*SnapshotResponse) Descriptor

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

func (*SnapshotResponse) GetAgentReturnCode

func (m *SnapshotResponse) GetAgentReturnCode() AgentErrorCode

func (*SnapshotResponse) GetOperationId

func (m *SnapshotResponse) GetOperationId() int32

func (*SnapshotResponse) GetScriptsReturnCode

func (m *SnapshotResponse) GetScriptsReturnCode() int32

func (*SnapshotResponse) GetType

func (m *SnapshotResponse) GetType() OperationType

func (*SnapshotResponse) ProtoMessage

func (*SnapshotResponse) ProtoMessage()

func (*SnapshotResponse) Reset

func (m *SnapshotResponse) Reset()

func (*SnapshotResponse) String

func (m *SnapshotResponse) String() string

func (*SnapshotResponse) XXX_DiscardUnknown

func (m *SnapshotResponse) XXX_DiscardUnknown()

func (*SnapshotResponse) XXX_Marshal

func (m *SnapshotResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SnapshotResponse) XXX_Merge

func (m *SnapshotResponse) XXX_Merge(src proto.Message)

func (*SnapshotResponse) XXX_Size

func (m *SnapshotResponse) XXX_Size() int

func (*SnapshotResponse) XXX_Unmarshal

func (m *SnapshotResponse) XXX_Unmarshal(b []byte) error

type SnapshotServiceClient

type SnapshotServiceClient interface {
	// The client is expected to first send a "GuestReady" message, indicating
	// they are available and establishing the connection that vanadium writes
	// requests to the agent on.
	CreateConnection(ctx context.Context, in *GuestReady, opts ...grpc.CallOption) (SnapshotService_CreateConnectionClient, error)
	// Handles the agent's responses to the above requests.
	HandleResponsesFromGuest(ctx context.Context, in *SnapshotResponse, opts ...grpc.CallOption) (*ServerAck, error)
}

SnapshotServiceClient is the client API for SnapshotService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewSnapshotServiceClient

func NewSnapshotServiceClient(cc *grpc.ClientConn) SnapshotServiceClient

type SnapshotServiceServer

type SnapshotServiceServer interface {
	// The client is expected to first send a "GuestReady" message, indicating
	// they are available and establishing the connection that vanadium writes
	// requests to the agent on.
	CreateConnection(*GuestReady, SnapshotService_CreateConnectionServer) error
	// Handles the agent's responses to the above requests.
	HandleResponsesFromGuest(context.Context, *SnapshotResponse) (*ServerAck, error)
}

SnapshotServiceServer is the server API for SnapshotService service.

type SnapshotService_CreateConnectionClient

type SnapshotService_CreateConnectionClient interface {
	Recv() (*GuestMessage, error)
	grpc.ClientStream
}

type SnapshotService_CreateConnectionServer

type SnapshotService_CreateConnectionServer interface {
	Send(*GuestMessage) error
	grpc.ServerStream
}

type SupportedFeatures

type SupportedFeatures int32
const (
	SupportedFeatures_NONE      SupportedFeatures = 0
	SupportedFeatures_SNAPSHOTS SupportedFeatures = 1
)

func (SupportedFeatures) EnumDescriptor

func (SupportedFeatures) EnumDescriptor() ([]byte, []int)

func (SupportedFeatures) String

func (x SupportedFeatures) String() string

type UnimplementedSnapshotServiceServer

type UnimplementedSnapshotServiceServer struct {
}

UnimplementedSnapshotServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedSnapshotServiceServer) CreateConnection

func (*UnimplementedSnapshotServiceServer) HandleResponsesFromGuest

func (*UnimplementedSnapshotServiceServer) HandleResponsesFromGuest(ctx context.Context, req *SnapshotResponse) (*ServerAck, error)

Jump to

Keyboard shortcuts

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