frostfs

package
v0.31.0-rc.6 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2024 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsErrObjectAccessDenied

func IsErrObjectAccessDenied(err error) (string, bool)

func IsTimeoutError

func IsTimeoutError(err error) bool

func UnwrapErr

func UnwrapErr(err error) error

Types

type FrostFS

type FrostFS struct {
	// contains filtered or unexported fields
}

FrostFS represents virtual connection to the FrostFS network. It is used to provide an interface to dependent packages which work with FrostFS.

func NewFrostFS

func NewFrostFS(p *pool.Pool) *FrostFS

NewFrostFS creates new FrostFS using provided pool.Pool.

func (*FrostFS) Container

func (x *FrostFS) Container(ctx context.Context, containerPrm handler.PrmContainer) (*container.Container, error)

Container implements frostfs.FrostFS interface method.

func (*FrostFS) CreateObject

func (x *FrostFS) CreateObject(ctx context.Context, prm handler.PrmObjectCreate) (oid.ID, error)

CreateObject implements frostfs.FrostFS interface method.

func (*FrostFS) GetEpochDurations

func (x *FrostFS) GetEpochDurations(ctx context.Context) (*utils.EpochDurations, error)

GetEpochDurations implements frostfs.FrostFS interface method.

func (*FrostFS) GetObject

func (x *FrostFS) GetObject(ctx context.Context, prm handler.PrmObjectGet) (*handler.Object, error)

GetObject implements frostfs.FrostFS interface method.

func (*FrostFS) HeadObject

func (x *FrostFS) HeadObject(ctx context.Context, prm handler.PrmObjectHead) (*object.Object, error)

HeadObject implements frostfs.FrostFS interface method.

func (*FrostFS) InitFrostFSObjectPayloadReader

func (x *FrostFS) InitFrostFSObjectPayloadReader(ctx context.Context, p GetFrostFSParams) (io.ReadCloser, error)

InitFrostFSObjectPayloadReader initializes payload reader of the FrostFS object. Zero range corresponds to full payload (panics if only offset is set).

func (*FrostFS) InitMultiObjectReader

func (x *FrostFS) InitMultiObjectReader(ctx context.Context, p handler.PrmInitMultiObjectReader) (io.Reader, error)

func (*FrostFS) RangeObject

func (x *FrostFS) RangeObject(ctx context.Context, prm handler.PrmObjectRange) (io.ReadCloser, error)

RangeObject implements frostfs.FrostFS interface method.

func (*FrostFS) SearchObjects

SearchObjects implements frostfs.FrostFS interface method.

type GetFrostFSParams

type GetFrostFSParams struct {
	// payload range
	Off, Ln uint64
	Addr    oid.Address
}

type GetNodeByPathResponseInfoWrapper

type GetNodeByPathResponseInfoWrapper struct {
	// contains filtered or unexported fields
}

func (GetNodeByPathResponseInfoWrapper) GetMeta

func (GetNodeByPathResponseInfoWrapper) GetNodeID

func (n GetNodeByPathResponseInfoWrapper) GetNodeID() []uint64

func (GetNodeByPathResponseInfoWrapper) GetParentID

func (n GetNodeByPathResponseInfoWrapper) GetParentID() []uint64

func (GetNodeByPathResponseInfoWrapper) GetTimestamp

func (n GetNodeByPathResponseInfoWrapper) GetTimestamp() []uint64

type GetSubTreeResponseBodyWrapper added in v0.31.0

type GetSubTreeResponseBodyWrapper struct {
	// contains filtered or unexported fields
}

func (GetSubTreeResponseBodyWrapper) GetMeta added in v0.31.0

func (n GetSubTreeResponseBodyWrapper) GetMeta() []tree.Meta

func (GetSubTreeResponseBodyWrapper) GetNodeID added in v0.31.0

func (n GetSubTreeResponseBodyWrapper) GetNodeID() []uint64

func (GetSubTreeResponseBodyWrapper) GetParentID added in v0.31.0

func (n GetSubTreeResponseBodyWrapper) GetParentID() []uint64

func (GetSubTreeResponseBodyWrapper) GetTimestamp added in v0.31.0

func (n GetSubTreeResponseBodyWrapper) GetTimestamp() []uint64

type MultiObjectReader

type MultiObjectReader struct {
	// contains filtered or unexported fields
}

MultiObjectReader implements io.Reader of payloads of the object list stored in the FrostFS network.

func (*MultiObjectReader) Read

func (x *MultiObjectReader) Read(p []byte) (n int, err error)

type MultiObjectReaderConfig

type MultiObjectReaderConfig struct {
	Initiator readerInitiator

	// the offset of complete object and total size to read
	Off, Ln uint64

	Addr  oid.Address
	Parts []PartObj
}

type PartInfo

type PartInfo struct {
	Key      string    `json:"key"`
	UploadID string    `json:"uploadId"`
	Number   int       `json:"number"`
	OID      oid.ID    `json:"oid"`
	Size     uint64    `json:"size"`
	ETag     string    `json:"etag"`
	MD5      string    `json:"md5"`
	Created  time.Time `json:"created"`
}

PartInfo is upload information about part.

type PartObj

type PartObj struct {
	OID  oid.ID
	Size uint64
}

type PoolWrapper

type PoolWrapper struct {
	// contains filtered or unexported fields
}

func NewPoolWrapper

func NewPoolWrapper(p *treepool.Pool) *PoolWrapper

func (*PoolWrapper) GetNodes

func (w *PoolWrapper) GetNodes(ctx context.Context, prm *tree.GetNodesParams) ([]tree.NodeResponse, error)

func (*PoolWrapper) GetSubTree added in v0.31.0

func (w *PoolWrapper) GetSubTree(ctx context.Context, bktInfo *data.BucketInfo, treeID string, rootID []uint64, depth uint32, sort bool) ([]tree.NodeResponse, error)

type ResolverFrostFS

type ResolverFrostFS struct {
	// contains filtered or unexported fields
}

ResolverFrostFS represents virtual connection to the FrostFS network. It implements resolver.FrostFS.

func NewResolverFrostFS

func NewResolverFrostFS(p *pool.Pool) *ResolverFrostFS

NewResolverFrostFS creates new ResolverFrostFS using provided pool.Pool.

func (*ResolverFrostFS) SystemDNS

func (x *ResolverFrostFS) SystemDNS(ctx context.Context) (string, error)

SystemDNS implements resolver.FrostFS interface method.

Jump to

Keyboard shortcuts

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