logstore

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2026 License: GPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrLogNotFound = fmt.Errorf("log not found")
)

Functions

func MigrateTarLog

func MigrateTarLog(ls *LogStore, logTar string) error

func MigrateTarLogsInDir

func MigrateTarLogsInDir(ls *LogStore, dir string)

Types

type LogMetadata added in v1.11.0

type LogMetadata struct {
	ID             string
	ExpirationTime time.Time // Expiration time of the log, zero if no expiration
	OwnerOpID      int64     // ID of the operation that owns this log
}

type LogStore

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

func NewLogStore

func NewLogStore(dir string) (*LogStore, error)

func (*LogStore) Close

func (ls *LogStore) Close() error

func (*LogStore) Create

func (ls *LogStore) Create(id string, parentOpID int64, ttl time.Duration) (io.WriteCloser, error)

func (*LogStore) Delete

func (ls *LogStore) Delete(id string) error

func (*LogStore) DeleteWithParent

func (ls *LogStore) DeleteWithParent(parentOpID int64) error

func (*LogStore) FindLogsWithParent added in v1.11.0

func (ls *LogStore) FindLogsWithParent(parentOpID int64) ([]string, error)

Find logs owned by a specific operation ID.

func (*LogStore) GetMetadata added in v1.11.0

func (ls *LogStore) GetMetadata(id string) (LogMetadata, error)

func (*LogStore) Open

func (ls *LogStore) Open(id string) (io.ReadCloser, error)

func (*LogStore) SelectAll

func (ls *LogStore) SelectAll(f func(id string, parentID int64)) error

Jump to

Keyboard shortcuts

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