Documentation

Overview

Package pdm is a generated protocol buffer package.

It is generated from these files:

pdm.proto

It has these top-level messages:

Endpoint
Handle
ActionItem
ActionStatus
Empty

Index

Constants

This section is empty.

Variables

var Command_name = map[int32]string{
	0: "NONE",
	1: "ARCHIVE",
	2: "RESTORE",
	3: "REMOVE",
	4: "CANCEL",
}

var Command_value = map[string]int32{
	"NONE":    0,
	"ARCHIVE": 1,
	"RESTORE": 2,
	"REMOVE":  3,
	"CANCEL":  4,
}

Functions

func RegisterDataMoverServer

func RegisterDataMoverServer(s *grpc.Server, srv DataMoverServer)

Types

type ActionItem

type ActionItem struct {
	Id          uint64  `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	Op          Command `protobuf:"varint,2,opt,name=op,enum=pdm.Command" json:"op,omitempty"`
	PrimaryPath string  `protobuf:"bytes,3,opt,name=primary_path,json=primaryPath" json:"primary_path,omitempty"`
	WritePath   string  `protobuf:"bytes,4,opt,name=write_path,json=writePath" json:"write_path,omitempty"`
	Offset      int64   `protobuf:"varint,5,opt,name=offset" json:"offset,omitempty"`
	Length      int64   `protobuf:"varint,6,opt,name=length" json:"length,omitempty"`
	Deprecated1 []byte  `protobuf:"bytes,7,opt,name=deprecated1,proto3" json:"deprecated1,omitempty"`
	Data        []byte  `protobuf:"bytes,8,opt,name=data,proto3" json:"data,omitempty"`
	Uuid        string  `protobuf:"bytes,9,opt,name=uuid" json:"uuid,omitempty"`
	Hash        []byte  `protobuf:"bytes,10,opt,name=hash,proto3" json:"hash,omitempty"`
	Url         string  `protobuf:"bytes,12,opt,name=url" json:"url,omitempty"`
}

func (*ActionItem) Descriptor

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

func (*ActionItem) ProtoMessage

func (*ActionItem) ProtoMessage()

func (*ActionItem) Reset

func (m *ActionItem) Reset()

func (*ActionItem) String

func (m *ActionItem) String() string

type ActionStatus

type ActionStatus struct {
	Id          uint64  `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	Completed   bool    `protobuf:"varint,2,opt,name=completed" json:"completed,omitempty"`
	Error       int32   `protobuf:"varint,3,opt,name=error" json:"error,omitempty"`
	Offset      int64   `protobuf:"varint,4,opt,name=offset" json:"offset,omitempty"`
	Length      int64   `protobuf:"varint,5,opt,name=length" json:"length,omitempty"`
	Handle      *Handle `protobuf:"bytes,6,opt,name=handle" json:"handle,omitempty"`
	Depcreated1 []byte  `protobuf:"bytes,7,opt,name=depcreated1,proto3" json:"depcreated1,omitempty"`
	Flags       int32   `protobuf:"varint,8,opt,name=flags" json:"flags,omitempty"`
	Uuid        string  `protobuf:"bytes,9,opt,name=uuid" json:"uuid,omitempty"`
	Hash        []byte  `protobuf:"bytes,10,opt,name=hash,proto3" json:"hash,omitempty"`
	Url         string  `protobuf:"bytes,11,opt,name=url" json:"url,omitempty"`
}

func (*ActionStatus) Descriptor

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

func (*ActionStatus) GetHandle

func (m *ActionStatus) GetHandle() *Handle

func (*ActionStatus) ProtoMessage

func (*ActionStatus) ProtoMessage()

func (*ActionStatus) Reset

func (m *ActionStatus) Reset()

func (*ActionStatus) String

func (m *ActionStatus) String() string

type Command

type Command int32
const (
	Command_NONE    Command = 0
	Command_ARCHIVE Command = 1
	Command_RESTORE Command = 2
	Command_REMOVE  Command = 3
	Command_CANCEL  Command = 4
)

func (Command) EnumDescriptor

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

func (Command) String

func (x Command) String() string

type DataMoverClient

type DataMoverClient interface {
	Register(ctx context.Context, in *Endpoint, opts ...grpc.CallOption) (*Handle, error)
	GetActions(ctx context.Context, in *Handle, opts ...grpc.CallOption) (DataMover_GetActionsClient, error)
	StatusStream(ctx context.Context, opts ...grpc.CallOption) (DataMover_StatusStreamClient, error)
}

func NewDataMoverClient

func NewDataMoverClient(cc *grpc.ClientConn) DataMoverClient

type DataMoverServer

type DataMoverServer interface {
	Register(context.Context, *Endpoint) (*Handle, error)
	GetActions(*Handle, DataMover_GetActionsServer) error
	StatusStream(DataMover_StatusStreamServer) error
}

type DataMover_GetActionsClient

type DataMover_GetActionsClient interface {
	Recv() (*ActionItem, error)
	grpc.ClientStream
}

type DataMover_GetActionsServer

type DataMover_GetActionsServer interface {
	Send(*ActionItem) error
	grpc.ServerStream
}

type DataMover_StatusStreamClient

type DataMover_StatusStreamClient interface {
	Send(*ActionStatus) error
	CloseAndRecv() (*Empty, error)
	grpc.ClientStream
}

type DataMover_StatusStreamServer

type DataMover_StatusStreamServer interface {
	SendAndClose(*Empty) error
	Recv() (*ActionStatus, error)
	grpc.ServerStream
}

type Empty

type Empty struct {
}

func (*Empty) Descriptor

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

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) Reset

func (m *Empty) Reset()

func (*Empty) String

func (m *Empty) String() string

type Endpoint

type Endpoint struct {
	FsUrl   string `protobuf:"bytes,2,opt,name=fs_url,json=fsUrl" json:"fs_url,omitempty"`
	Archive uint32 `protobuf:"varint,1,opt,name=archive" json:"archive,omitempty"`
}

func (*Endpoint) Descriptor

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

func (*Endpoint) ProtoMessage

func (*Endpoint) ProtoMessage()

func (*Endpoint) Reset

func (m *Endpoint) Reset()

func (*Endpoint) String

func (m *Endpoint) String() string

type Handle

type Handle struct {
	Id uint64 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
}

func (*Handle) Descriptor

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

func (*Handle) ProtoMessage

func (*Handle) ProtoMessage()

func (*Handle) Reset

func (m *Handle) Reset()

func (*Handle) String

func (m *Handle) String() string

Source Files