api

package
v0.0.0-...-26dc691 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2023 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AnyCert bool
View Source
var NOSHUTDOWN bool
View Source
var ServerCACert string
View Source
var ServerCert string
View Source
var ServerKey string
View Source
var ServerMtls bool
View Source
var ServerTls bool

Functions

func LoadKeyPair

func LoadKeyPair(mtls, anycert bool, rtls bool) (*credentials.TransportCredentials, error)

func ReloadEncryptionClient

func ReloadEncryptionClient(conn []*grpc.ClientConn) error

func StartServer

func StartServer(Connections map[int64]*grpc.ClientConn, pclnts map[int64]*pool.Pool, port string, enableAuth bool, dedupe map[int64]ForwardEntry, proxy, debug bool, pwd string, pr *PortRedictor, remoteServerCert bool)

func StopServer

func StopServer()

Types

type FileIOProxy

type FileIOProxy struct {
	spb.UnimplementedFileIOServiceServer
	// contains filtered or unexported fields
}

func NewFileIOProxy

func NewFileIOProxy(clnts map[int64]*grpc.ClientConn, pclnts map[int64]*pool.Pool, dedupeEnabled map[int64]ForwardEntry, proxy, debug bool) (*FileIOProxy, error)

func (*FileIOProxy) Chmod

func (*FileIOProxy) Chown

func (*FileIOProxy) CopyExtent

func (*FileIOProxy) CreateCopy

func (*FileIOProxy) FileExists

func (*FileIOProxy) Flush

func (*FileIOProxy) Fsync

func (*FileIOProxy) GetAttr

func (s *FileIOProxy) GetAttr(ctx context.Context, req *spb.StatRequest) (*spb.StatResponse, error)

func (*FileIOProxy) GetCloudFile

func (*FileIOProxy) GetCloudMetaFile

func (s *FileIOProxy) GetCloudMetaFile(ctx context.Context, req *spb.GetCloudFileRequest) (*spb.GetCloudFileResponse, error)

func (*FileIOProxy) GetFileInfo

func (*FileIOProxy) GetRetrievalTier

func (*FileIOProxy) GetXAttr

func (*FileIOProxy) GetXAttrSize

func (*FileIOProxy) GetaAllFileInfo

func (*FileIOProxy) MkDir

func (*FileIOProxy) MkDirAll

func (s *FileIOProxy) MkDirAll(ctx context.Context, req *spb.MkDirRequest) (*spb.MkDirResponse, error)

func (*FileIOProxy) Mknod

func (*FileIOProxy) Open

func (*FileIOProxy) Read

func (s *FileIOProxy) ReadLink(ctx context.Context, req *spb.LinkRequest) (*spb.LinkResponse, error)

func (*FileIOProxy) Release

func (*FileIOProxy) ReloadVolumeMap

func (s *FileIOProxy) ReloadVolumeMap(clnts map[int64]*grpc.ClientConn, pclnts map[int64]*pool.Pool, dedupeEnabled map[int64]ForwardEntry, debug bool) error

func (*FileIOProxy) RemoveXAttr

func (*FileIOProxy) Rename

func (*FileIOProxy) RmDir

func (*FileIOProxy) SetRetrievalTier

func (*FileIOProxy) SetUserMetaData

func (*FileIOProxy) SetXAttr

func (*FileIOProxy) Stat

func (*FileIOProxy) StatFS

func (*FileIOProxy) Truncate

func (*FileIOProxy) Utime

func (*FileIOProxy) Write

type ForwardEntry

type ForwardEntry struct {
	Pwd           string `json:"pwd"`
	User          string `json:"user"`
	Lpwd          string `json:"local-auth"`
	Address       string `json:"address" required:"true"`
	DisableTrust  bool   `json:"trust-all"`
	Mtls          bool   `json:"mtls"`
	Mtlsca        string `json:"root-ca"`
	Mtlskey       string `json:"mtls-key"`
	Mtlscert      string `json:"mtls-cert"`
	Dedupe        bool   `json:"dedupe"`
	DedupeThreads int    `json:"dedupe-threads" default:"8"`
	DedupeBuffer  int    `json:"dedupe-buffer" default:"4"`
	CompressData  bool   `json:"compress"`
	CacheSize     int    `json:"dedupe-cache-size" default:"1000000"`
	CacheAge      int    `json:"dedupe-cache-age" default:"30"`
}

type PortRedictor

type PortRedictor struct {
	spb.UnimplementedPortRedirectorServiceServer

	Cmp     map[int64]*grpc.ClientConn
	Cmppool map[int64]*pool.Pool

	Dd map[int64]ForwardEntry
	// contains filtered or unexported fields
}

func NewPortRedirector

func NewPortRedirector(config string, listenPort string, portforwarder bool, clnt *grpc.ClientConn, debug bool) *PortRedictor

func (*PortRedictor) GetProxyVolumes

func (*PortRedictor) ReloadConfig

func (*PortRedictor) WriteConfig

func (s *PortRedictor) WriteConfig() error

type PortRedirectors

type PortRedirectors struct {
	ListenPort    string         `json:"port"`
	ForwardEntrys []ForwardEntry `json:"forwarders"`
}

type SDFSEventProxy

type SDFSEventProxy struct {
	spb.UnimplementedSDFSEventServiceServer
	// contains filtered or unexported fields
}

func NewEventProxy

func NewEventProxy(clnts map[int64]*grpc.ClientConn, proxy, debug bool) *SDFSEventProxy

func (*SDFSEventProxy) GetEvent

func (*SDFSEventProxy) GetEvents

func (*SDFSEventProxy) ListEvents

func (*SDFSEventProxy) ReloadVolumeMap

func (s *SDFSEventProxy) ReloadVolumeMap(clnts map[int64]*grpc.ClientConn, debug bool) error

func (*SDFSEventProxy) SubscribeEvent

type StorageServiceProxy

type StorageServiceProxy struct {
	spb.UnimplementedStorageServiceServer
	// contains filtered or unexported fields
}

func NewStorageService

func NewStorageService(clnts map[int64]*grpc.ClientConn, pclnts map[int64]*pool.Pool, proxy, debug bool) *StorageServiceProxy

func (*StorageServiceProxy) AddReplicaSource

func (*StorageServiceProxy) CancelReplication

func (*StorageServiceProxy) CheckHashes

func (*StorageServiceProxy) GetChunks

func (*StorageServiceProxy) GetMetaDataDedupeFile

func (*StorageServiceProxy) GetSparseDedupeFile

func (*StorageServiceProxy) HashingInfo

func (*StorageServiceProxy) ListReplLogs

func (*StorageServiceProxy) PauseReplication

func (*StorageServiceProxy) ReadSparseDataChunk

func (*StorageServiceProxy) ReloadVolumeMap

func (s *StorageServiceProxy) ReloadVolumeMap(clnts map[int64]*grpc.ClientConn, debug bool) error

func (*StorageServiceProxy) RemoveReplicaSource

func (*StorageServiceProxy) ReplicateRemoteFile

func (*StorageServiceProxy) RestoreArchives

func (*StorageServiceProxy) SubscribeToVolume

func (*StorageServiceProxy) WriteChunks

func (*StorageServiceProxy) WriteChunksStream

func (*StorageServiceProxy) WriteSparseDataChunk

type VolumeProxy

type VolumeProxy struct {
	spb.UnimplementedVolumeServiceServer

	Clnt map[int64]*grpc.ClientConn
	// contains filtered or unexported fields
}

func NewVolumeProxy

func NewVolumeProxy(clnts map[int64]*grpc.ClientConn, password string, proxy, debug bool) *VolumeProxy

func (*VolumeProxy) AuthenticateUser

func (*VolumeProxy) CleanStore

func (*VolumeProxy) DSEInfo

func (s *VolumeProxy) DSEInfo(ctx context.Context, req *spb.DSERequest) (*spb.DSEResponse, error)

func (*VolumeProxy) DeleteCloudVolume

func (*VolumeProxy) GetConnectedVolumes

func (s *VolumeProxy) GetConnectedVolumes(ctx context.Context, req *spb.CloudVolumesRequest) (*spb.CloudVolumesResponse, error)

func (*VolumeProxy) GetGCSchedule

func (s *VolumeProxy) GetGCSchedule(ctx context.Context, req *spb.GCScheduleRequest) (*spb.GCScheduleResponse, error)

func (*VolumeProxy) GetVolumeInfo

func (s *VolumeProxy) GetVolumeInfo(ctx context.Context, req *spb.VolumeInfoRequest) (*spb.VolumeInfoResponse, error)

func (*VolumeProxy) ReloadVolumeMap

func (s *VolumeProxy) ReloadVolumeMap(clnts map[int64]*grpc.ClientConn, debug bool) error

func (*VolumeProxy) SetCacheSize

func (*VolumeProxy) SetMaxAge

func (*VolumeProxy) SetReadSpeed

func (s *VolumeProxy) SetReadSpeed(ctx context.Context, req *spb.SpeedRequest) (*spb.SpeedResponse, error)

func (*VolumeProxy) SetVolumeCapacity

func (*VolumeProxy) SetWriteSpeed

func (s *VolumeProxy) SetWriteSpeed(ctx context.Context, req *spb.SpeedRequest) (*spb.SpeedResponse, error)

func (*VolumeProxy) ShutdownVolume

func (s *VolumeProxy) ShutdownVolume(ctx context.Context, req *spb.ShutdownRequest) (*spb.ShutdownResponse, error)

func (*VolumeProxy) SyncCloudVolume

func (s *VolumeProxy) SyncCloudVolume(ctx context.Context, req *spb.SyncVolRequest) (*spb.SyncVolResponse, error)

func (*VolumeProxy) SyncFromCloudVolume

func (s *VolumeProxy) SyncFromCloudVolume(ctx context.Context, req *spb.SyncFromVolRequest) (*spb.SyncFromVolResponse, error)

func (*VolumeProxy) SystemInfo

Jump to

Keyboard shortcuts

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