cachingreader

package
v0.3.4 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: Apache-2.0 Imports: 18 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ObjectServer

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

func NewObjectServer

func NewObjectServer(baseDir string, maxCachedBytes uint64,
	objectServerAddress string, logger log.DebugLogger) (*ObjectServer, error)

func (*ObjectServer) FetchObjects

func (objSrv *ObjectServer) FetchObjects(hashes []hash.Hash) error

func (*ObjectServer) GetObjects

func (objSrv *ObjectServer) GetObjects(hashes []hash.Hash) (
	objectserver.ObjectsReader, error)

func (*ObjectServer) GetStats added in v0.3.4

func (objSrv *ObjectServer) GetStats() Stats

func (*ObjectServer) LinkObject

func (objSrv *ObjectServer) LinkObject(filename string,
	hashVal hash.Hash) (bool, error)

func (*ObjectServer) WriteHtml

func (objSrv *ObjectServer) WriteHtml(writer io.Writer)

type Stats added in v0.3.4

type Stats struct {
	CachedBytes      uint64 // Includes LruBytes.
	DownloadingBytes uint64 // Objects being downloaded and cached.
	LruBytes         uint64 // Cached but not in-use objects.

}

Jump to

Keyboard shortcuts

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