hashstore

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2024 License: AGPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadFull

func ReadFull(path string, data []byte) ([]byte, error)

Types

type Compact

type Compact struct {
	Dir string `usage:"directory of the store (not the db!)" default:"/tmp/store"`
}

func (*Compact) Run

func (i *Compact) Run() error

type Convert

type Convert struct {
	Dir         string
	Destination string
	SatelliteID storj.NodeID
}

func (*Convert) Copy

func (i *Convert) Copy(ctx context.Context, store blobstore.Blobs, op *piecestore.HashStoreBackend, info blobstore.BlobInfo, buf []byte, header *pb.PieceHeader) (err error)

func (*Convert) Run

func (i *Convert) Run() error

type Generate added in v1.1.0

type Generate struct {
	load.PieceIDStream
	Dir          string        `usage:"directory of the store (not the db!)" default:"/tmp/store"`
	Samples      int           `usage:"number of pieces to be written" default:"1"`
	Size         int64         `usage:"size of the pieces to be written" default:"100000"`
	TTL          time.Duration `usage:"TTL to be used"`
	TTLModulo    int           `usage:"modulo for TTL. Only the selected pieces with this modulo will be TTLed" default:"1"`
	MinTableSize uint64        `usage:"minimum table size for the store" default:"20"`
	MetaPath     string        `usage:"path to the meta file" default:""`
}

func (Generate) Run added in v1.1.0

func (b Generate) Run() error

type Hashstore

type Hashstore struct {
	Convert Convert `cmd:"" usage:"import data to the hashtable"`
	List    List    `cmd:"" usage:"list content of a hashtable"`
	Stat    Stat    `cmd:"" usage:"list content of a hashtable stat"`
	//Generate Generate `cmd:"" usage:"generate data to a hashtable store"`
	Compact Compact `cmd:"" usage:"compact a hashtable store"`
	Report  Report  `cmd:"" usage:"show additional reports on a hashtable store"`
}

type List

type List struct {
	Path string `arg:""`
}

func (*List) Run

func (i *List) Run() error

type Report added in v1.1.0

type Report struct {
	Path string `arg:""`
}

func (*Report) Run added in v1.1.0

func (i *Report) Run() error

type Stat added in v1.1.0

type Stat struct {
	Path string `arg:""`
}

func (*Stat) Run added in v1.1.0

func (i *Stat) Run() error

Jump to

Keyboard shortcuts

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