metainfo

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2019 License: AGPL-3.0 Imports: 23 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// Error general metainfo error
	Error = errs.Class("metainfo error")
)

Functions

func CreatePath

func CreatePath(projectID uuid.UUID, segmentIndex int64, bucket, path []byte) (storj.Path, error)

CreatePath will create a Segment path

Types

type APIKeys

type APIKeys interface {
	GetByKey(ctx context.Context, key console.APIKey) (*console.APIKeyInfo, error)
}

APIKeys is api keys store methods used by endpoint

type Endpoint

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

Endpoint metainfo endpoint

func NewEndpoint

func NewEndpoint(log *zap.Logger, pointerdb *pointerdb.Service, orders *orders.Service, cache *overlay.Cache, apiKeys APIKeys, acctDB accounting.DB, maxAlphaUsage memory.Size) *Endpoint

NewEndpoint creates new metainfo endpoint instance

func (*Endpoint) Close

func (endpoint *Endpoint) Close() error

Close closes resources

func (*Endpoint) CommitSegment

func (endpoint *Endpoint) CommitSegment(ctx context.Context, req *pb.SegmentCommitRequest) (resp *pb.SegmentCommitResponse, err error)

CommitSegment commits segment metadata

func (*Endpoint) CreateSegment

func (endpoint *Endpoint) CreateSegment(ctx context.Context, req *pb.SegmentWriteRequest) (resp *pb.SegmentWriteResponse, err error)

CreateSegment will generate requested number of OrderLimit with coresponding node addresses for them

func (*Endpoint) DeleteSegment

func (endpoint *Endpoint) DeleteSegment(ctx context.Context, req *pb.SegmentDeleteRequest) (resp *pb.SegmentDeleteResponse, err error)

DeleteSegment deletes segment metadata from satellite and returns OrderLimit array to remove them from storage node

func (*Endpoint) DownloadSegment

func (endpoint *Endpoint) DownloadSegment(ctx context.Context, req *pb.SegmentDownloadRequest) (resp *pb.SegmentDownloadResponse, err error)

DownloadSegment gets Pointer incase of INLINE data or list of OrderLimit necessary to download remote data

func (*Endpoint) ListSegments

func (endpoint *Endpoint) ListSegments(ctx context.Context, req *pb.ListSegmentsRequest) (resp *pb.ListSegmentsResponse, err error)

ListSegments returns all Path keys in the Pointers bucket

func (*Endpoint) SegmentInfo

func (endpoint *Endpoint) SegmentInfo(ctx context.Context, req *pb.SegmentInfoRequest) (resp *pb.SegmentInfoResponse, err error)

SegmentInfo returns segment metadata info

Jump to

Keyboard shortcuts

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