Versions in this module Expand all Collapse all v1 v1.0.1 Mar 1, 2020 Changes in this version + const DefaultHealth + const DirFileName + var ErrAlreadyDeleted = errors.New("DxDir has already been deleted") + var ErrPathOverload = errors.New("a file already exists at that location") + var ErrUnknownPath = errors.New("no file known with that path") + var ErrUploadDirectory = errors.New("cannot upload directory") + type DirSet struct + func NewDirSet(rootDir storage.SysPath, wal *writeaheadlog.Wal) (*DirSet, error) + func (ds *DirSet) Delete(path storage.DxPath) error + func (ds *DirSet) Exists(path storage.DxPath) bool + func (ds *DirSet) NewDxDir(path storage.DxPath) (*DirSetEntryWithID, error) + func (ds *DirSet) Open(path storage.DxPath) (*DirSetEntryWithID, error) + func (ds *DirSet) UpdateMetadata(path storage.DxPath, metadata Metadata) error + type DirSetEntryWithID struct + func (entry *DirSetEntryWithID) Close() error + type DxDir struct + func New(dxPath storage.DxPath, rootPath storage.SysPath, wal *writeaheadlog.Wal) (*DxDir, error) + func (d *DxDir) DecodeRLP(st *rlp.Stream) error + func (d *DxDir) Delete() error + func (d *DxDir) Deleted() bool + func (d *DxDir) DxPath() storage.DxPath + func (d *DxDir) EncodeRLP(w io.Writer) error + func (d *DxDir) FilePath() string + func (d *DxDir) Metadata() Metadata + func (d *DxDir) UpdateMetadata(metadata Metadata) error + type Metadata struct + DxPath storage.DxPath + Health uint32 + MinRedundancy uint32 + NumFiles uint64 + NumStuckSegments uint32 + RootPath storage.SysPath + StuckHealth uint32 + TimeLastHealthCheck uint64 + TimeModify uint64 + TotalSize uint64