store

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2024 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLoader

func NewLoader(lg *zap.Logger, cfg LoaderCfg) *loader

func NewWriter

func NewWriter(cfg WriterCfg) *writer

Types

type LoaderCfg

type LoaderCfg struct {
	Dir string
}

type Meta

type Meta struct {
	Version      string
	Duration     time.Duration
	Cmds         uint64
	FilteredCmds uint64
}

func NewMeta

func NewMeta(duration time.Duration, cmds, filteredCmds uint64) *Meta

func (*Meta) Read

func (m *Meta) Read(path string) error

func (*Meta) Write

func (m *Meta) Write(path string) error

type Writer

type Writer interface {
	Write([]byte) error
	Close() error
}

type WriterCfg

type WriterCfg struct {
	Dir      string
	FileSize int
}

Jump to

Keyboard shortcuts

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